mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-10 07:12:07 +00:00
Fix several printf format string errors in games' code
Submitted by: Ozkan Sezer
This commit is contained in:
parent
126eb09a1e
commit
91245e3b70
3 changed files with 6 additions and 6 deletions
|
@ -159,7 +159,7 @@ Sys_Error(char *error, ...)
|
||||||
vsprintf(text, error, argptr);
|
vsprintf(text, error, argptr);
|
||||||
va_end(argptr);
|
va_end(argptr);
|
||||||
|
|
||||||
gi.error(ERR_FATAL, "%s", text);
|
gi.error("%s", text);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -808,7 +808,7 @@ SV_Physics_Pusher(edict_t *ent)
|
||||||
|
|
||||||
if (pushed_p > &pushed[MAX_EDICTS])
|
if (pushed_p > &pushed[MAX_EDICTS])
|
||||||
{
|
{
|
||||||
gi.error(ERR_FATAL, "pushed_p > &pushed[MAX_EDICTS], memory corrupted");
|
gi.error("pushed_p > &pushed[MAX_EDICTS], memory corrupted");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (part)
|
if (part)
|
||||||
|
|
|
@ -251,8 +251,8 @@ InitGame(void)
|
||||||
/* items */
|
/* items */
|
||||||
InitItems();
|
InitItems();
|
||||||
|
|
||||||
Com_sprintf(game.helpmessage1, sizeof(game.helpmessage1), "");
|
game.helpmessage1[0] = 0;
|
||||||
Com_sprintf(game.helpmessage2, sizeof(game.helpmessage2), "");
|
game.helpmessage2[0] = 0;
|
||||||
|
|
||||||
/* initialize all entities for this game */
|
/* initialize all entities for this game */
|
||||||
game.maxentities = maxentities->value;
|
game.maxentities = maxentities->value;
|
||||||
|
@ -648,7 +648,7 @@ ReadField(FILE *f, field_t *field, byte *base)
|
||||||
if (len > sizeof(funcStr))
|
if (len > sizeof(funcStr))
|
||||||
{
|
{
|
||||||
gi.error ("ReadField: function name is longer than buffer (%i chars)",
|
gi.error ("ReadField: function name is longer than buffer (%i chars)",
|
||||||
sizeof(funcStr));
|
(int)sizeof(funcStr));
|
||||||
}
|
}
|
||||||
|
|
||||||
fread (funcStr, len, 1, f);
|
fread (funcStr, len, 1, f);
|
||||||
|
@ -672,7 +672,7 @@ ReadField(FILE *f, field_t *field, byte *base)
|
||||||
if (len > sizeof(funcStr))
|
if (len > sizeof(funcStr))
|
||||||
{
|
{
|
||||||
gi.error ("ReadField: mmove name is longer than buffer (%i chars)",
|
gi.error ("ReadField: mmove name is longer than buffer (%i chars)",
|
||||||
sizeof(funcStr));
|
(int)sizeof(funcStr));
|
||||||
}
|
}
|
||||||
|
|
||||||
fread (funcStr, len, 1, f);
|
fread (funcStr, len, 1, f);
|
||||||
|
|
Loading…
Reference in a new issue