1
0
Fork 0
forked from fte/fteqw

plugin.c: Fix return values so it compiles with g++ properly.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@6118 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Eukara 2021-11-09 16:53:31 +00:00
parent b01f2f69d8
commit d4bd64980f

View file

@ -124,7 +124,7 @@ qboolean VARGS Q_vsnprintfz (char *dest, size_t size, const char *fmt, va_list a
plugfuncs->Error("Q_vsnprintfz: Truncation\n");
#endif
//if ret is -1 (windows oversize, or general error) then it'll be treated as unsigned so really long. this makes the following check quite simple.
return ret>=size;
return (ret>=size) ? qtrue : qfalse;
}
//windows/linux have inconsistant snprintf
//this is an attempt to get them consistant and safe
@ -152,7 +152,7 @@ qboolean VARGS Q_snprintfz (char *dest, size_t size, const char *fmt, ...)
plugfuncs->Error("Q_vsnprintfz: Truncation\n");
#endif
//if ret is -1 (windows oversize, or general error) then it'll be treated as unsigned so really long. this makes the following check quite simple.
return ret>=size;
return (ret>=size) ? qtrue : qfalse;
}
char *va(const char *format, ...) //Identical in function to the one in Quake, though I can assure you that I wrote it...