ref: 30b05089f5edc8c7ab4435495efce7fa0bbb40df
parent: 38d9e11a7e6f117189b7349d62f08c2c151899c4
author: Turo Lamminen <[email protected]>
date: Sat Feb 17 10:53:50 EST 2018
Fix format string problems in R_DrawPlanes
--- a/src/doom/r_plane.c
+++ b/src/doom/r_plane.c
@@ -368,15 +368,15 @@
#ifdef RANGECHECK
if (ds_p - drawsegs > MAXDRAWSEGS)
- I_Error ("R_DrawPlanes: drawsegs overflow (%i)",
+ I_Error ("R_DrawPlanes: drawsegs overflow (%" PRIiPTR ")",
ds_p - drawsegs);
if (lastvisplane - visplanes > MAXVISPLANES)
- I_Error ("R_DrawPlanes: visplane overflow (%i)",
+ I_Error ("R_DrawPlanes: visplane overflow (%" PRIiPTR ")",
lastvisplane - visplanes);
if (lastopening - openings > MAXOPENINGS)
- I_Error ("R_DrawPlanes: opening overflow (%i)",
+ I_Error ("R_DrawPlanes: opening overflow (%" PRIiPTR ")",
lastopening - openings);
#endif
--- a/src/heretic/r_plane.c
+++ b/src/heretic/r_plane.c
@@ -386,12 +386,13 @@
#ifdef RANGECHECK
if (ds_p - drawsegs > MAXDRAWSEGS)
- I_Error("R_DrawPlanes: drawsegs overflow (%i)", ds_p - drawsegs);
+ I_Error("R_DrawPlanes: drawsegs overflow (%" PRIiPTR ")",
+ ds_p - drawsegs);
if (lastvisplane - visplanes > MAXVISPLANES)
- I_Error("R_DrawPlanes: visplane overflow (%i)",
+ I_Error("R_DrawPlanes: visplane overflow (%" PRIiPTR ")",
lastvisplane - visplanes);
if (lastopening - openings > MAXOPENINGS)
- I_Error("R_DrawPlanes: opening overflow (%i)",
+ I_Error("R_DrawPlanes: opening overflow (%" PRIiPTR ")",
lastopening - openings);
#endif
--- a/src/hexen/r_plane.c
+++ b/src/hexen/r_plane.c
@@ -390,16 +390,17 @@
#ifdef RANGECHECK
if (ds_p - drawsegs > MAXDRAWSEGS)
{
- I_Error("R_DrawPlanes: drawsegs overflow (%i)", ds_p - drawsegs);
+ I_Error("R_DrawPlanes: drawsegs overflow (%" PRIiPTR ")",
+ ds_p - drawsegs);
}
if (lastvisplane - visplanes > MAXVISPLANES)
{
- I_Error("R_DrawPlanes: visplane overflow (%i)",
+ I_Error("R_DrawPlanes: visplane overflow (%" PRIiPTR ")",
lastvisplane - visplanes);
}
if (lastopening - openings > MAXOPENINGS)
{
- I_Error("R_DrawPlanes: opening overflow (%i)",
+ I_Error("R_DrawPlanes: opening overflow (%" PRIiPTR ")",
lastopening - openings);
}
#endif
--- a/src/strife/r_plane.c
+++ b/src/strife/r_plane.c
@@ -369,15 +369,15 @@
#ifdef RANGECHECK
if (ds_p - drawsegs > MAXDRAWSEGS)
- I_Error ("R_DrawPlanes: drawsegs overflow (%i)",
+ I_Error ("R_DrawPlanes: drawsegs overflow (%" PRIiPTR ")",
ds_p - drawsegs);
if (lastvisplane - visplanes > MAXVISPLANES)
- I_Error ("R_DrawPlanes: visplane overflow (%i)",
+ I_Error ("R_DrawPlanes: visplane overflow (%" PRIiPTR ")",
lastvisplane - visplanes);
if (lastopening - openings > MAXOPENINGS)
- I_Error ("R_DrawPlanes: opening overflow (%i)",
+ I_Error ("R_DrawPlanes: opening overflow (%" PRIiPTR ")",
lastopening - openings);
#endif