Open jungle-boogie opened 8 years ago
Hi @jungle-boogie
I have tested this and it requires to change all strcpy
, strcat
and strprintf
calls in the code. After fixing the lines you reported it complains about other lines.
It seems the 'n' versions (strncpy
, strncat
, and so) of those functions doesn't make any waring and are more compatible with other OS.
This change affects more lines than expected so I'll do it when I have more spare time 0:) If somehow this cause crashes in sngrep, just let me know to fix it ASAP.
Thanks for reporting!!
Hello,
Compiling sngrep on openbsd 5.9 beta generates these warnings:
Here's the man page on the preferred openBSD choices of
strlcpy
andstrlcat
:http://www.openbsd.org/cgi-bin/man.cgi/OpenBSD-current/man3/strlcat.3?query=strlcat
For
vsnprintf
andsnprintf
:www.openbsd.org/cgi-bin/man.cgi?query=vsnprintf