fwrite crashes server
#2

https://sampwiki.blast.hk/wiki/Fwrite

By checking if the file handle is valid, it prevents the crash. So instead of doing this:
pawn Код:
new File: fhandle = fopen(...);
fwrite(fhandle, "...");
fclose(fhandle);
would be:
pawn Код:
new File: fhandle = fopen(...);
if (fhandle)
{
    fwrite(fhandle, "...");
    fclose(fhandle);
}
Reply


Messages In This Thread
fwrite crashes server - by Hotelgast - 08.06.2015, 08:32
Re: fwrite crashes server - by Konstantinos - 08.06.2015, 10:20

Forum Jump:


Users browsing this thread: 1 Guest(s)