nfqws2: AI inspired fixes

This commit is contained in:
bol-van
2026-02-04 22:06:23 +03:00
parent cfd2df41c4
commit 97a6b9dd5b
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -178,8 +178,8 @@ void extract_endpoints(const struct ip *ip,const struct ip6_hdr *ip6hdr,const st
}
else
{
memset(src,0,sizeof(*src));
memset(dst,0,sizeof(*dst));
if (src) memset(src,0,sizeof(*src));
if (dst) memset(dst,0,sizeof(*dst));
}
}
+1 -1
View File
@@ -413,7 +413,7 @@ ssize_t HttpPos(t_marker posmarker, int16_t pos, const uint8_t *data, size_t sz)
if (*method=='\n' || *method=='\r') method++;
if (*method=='\n' || *method=='\r') method++;
// max length is PROPPATCH
for (p=method,i=0;i<9;i++) if (*p>='A' && *p<='Z') p++;
for (p=method,i=0; i<9 && *p>='A' && *p<='Z'; i++,p++);
if (i<3 || *p!=' ') break;
return CheckPos(sz,method-data+pos);
case PM_HOST: