08.06.2015, 10:20
https://sampwiki.blast.hk/wiki/Fwrite
By checking if the file handle is valid, it prevents the crash. So instead of doing this:
would be:
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);
pawn Код:
new File: fhandle = fopen(...);
if (fhandle)
{
fwrite(fhandle, "...");
fclose(fhandle);
}