What is this warning in my server log ? how to fix it ? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: What is this warning in my server log ? how to fix it ? (
/showthread.php?tid=505834)
What is this warning in my server log ? how to fix it ? -
AnonScripter - 10.04.2014
Код:
[16:29:49] sscanf warning: String buffer overflow.
[16:31:28] sscanf warning: String buffer overflow.
[16:31:53] sscanf warning: String buffer overflow.
[16:32:09] sscanf warning: String buffer overflow.
[16:32:23] sscanf warning: String buffer overflow.
Re: What is this warning in my server log ? how to fix it ? -
Bingo - 10.04.2014
A cmd(s) string is crossing.
How ever, If you know which cmd then post here.
Re: What is this warning in my server log ? how to fix it ? -
Konstantinos - 10.04.2014
In simple words, it exceeds the size you specified in the sscanf line with the "s" specifier. An example:
pawn Код:
// in a /test command
if (sscanf(params, "is[10]", integer, string)) ...
and you type in-game: /test 10 abcdefghijklmnopqrstuvwxyz then the warning will be given because the max size was 10 but I typed something with lenght of 26.
Re: What is this warning in my server log ? how to fix it ? -
AnonScripter - 10.04.2014
oh thank you both, that's usefull