Template
1
0
mirror of https://github.com/bol-van/zapret2.git synced 2026-03-14 06:13:09 +00:00

AI inspired fixes

This commit is contained in:
bol-van
2026-01-30 19:18:17 +03:00
parent 2a2a3e4f73
commit 5f87b7670a
2 changed files with 3 additions and 3 deletions

View File

@@ -1435,8 +1435,8 @@ bool IsStunMessage(const uint8_t *data, size_t len)
return len>=20 && // header size
(data[0]&0xC0)==0 && // 2 most significant bits must be zeroes
(data[3]&3)==0 && // length must be a multiple of 4
ntohl(pntoh32(data+4))==0x2112A442 && // magic cookie
ntohs(pntoh16(data+2))==(len-20);
pntoh32(data+4)==0x2112A442 && // magic cookie
pntoh16(data+2)==(len-20);
}
#if defined(__GNUC__) && !defined(__llvm__)
__attribute__((optimize ("no-strict-aliasing")))