mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-01-19 08:01:50 +00:00
Fixed string format issues reported by GCC/Clang
d_net.cpp:2874:25: warning: format specifies type 'int' but the argument has type 'unsigned long long' [-Wformat] gl/utility/gl_clock.cpp:240:38: warning: format specifies type 'int' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Wformat] v_video.cpp:883:71: warning: format specifies type 'unsigned int' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Wformat] v_video.cpp:883:80: warning: format specifies type 'unsigned int' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Wformat]
This commit is contained in:
parent
eeba7a7cdf
commit
0667f2ec55
3 changed files with 6 additions and 3 deletions
|
@ -26,6 +26,7 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
|
||||
#include <stddef.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "version.h"
|
||||
#include "menu/menu.h"
|
||||
|
@ -2871,7 +2872,7 @@ CCMD (pings)
|
|||
int i;
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
if (playeringame[i])
|
||||
Printf ("% 4d %s\n", currrecvtime[i] - lastrecvtime[i],
|
||||
Printf ("% 4" PRId64 " %s\n", currrecvtime[i] - lastrecvtime[i],
|
||||
players[i].userinfo.GetName());
|
||||
}
|
||||
|
||||
|
|
|
@ -43,6 +43,8 @@
|
|||
#include <sys/sysctl.h>
|
||||
#endif
|
||||
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "i_system.h"
|
||||
#include "g_level.h"
|
||||
#include "c_console.h"
|
||||
|
@ -237,7 +239,7 @@ void CheckBench()
|
|||
AppendRenderTimes(compose);
|
||||
AppendLightStats(compose);
|
||||
AppendMissingTextureStats(compose);
|
||||
compose.AppendFormat("%d fps\n\n", screen->GetLastFPS());
|
||||
compose.AppendFormat("%" PRIu64 " fps\n\n", screen->GetLastFPS());
|
||||
|
||||
FILE *f = fopen("benchmarks.txt", "at");
|
||||
if (f != NULL)
|
||||
|
|
|
@ -880,7 +880,7 @@ void DFrameBuffer::DrawRateStuff ()
|
|||
|
||||
int textScale = active_con_scale();
|
||||
|
||||
chars = mysnprintf (fpsbuff, countof(fpsbuff), "%2u ms (%3u fps)", howlong, LastCount);
|
||||
chars = mysnprintf (fpsbuff, countof(fpsbuff), "%2" PRIu64 " ms (%3" PRIu64 " fps)", howlong, LastCount);
|
||||
rate_x = Width / textScale - ConFont->StringWidth(&fpsbuff[0]);
|
||||
Clear (rate_x * textScale, 0, Width, ConFont->GetHeight() * textScale, GPalette.BlackIndex, 0);
|
||||
DrawText (ConFont, CR_WHITE, rate_x, 0, (char *)&fpsbuff[0],
|
||||
|
|
Loading…
Reference in a new issue