test: portable 64bit address format specifier

main
Christian Rauch 2021-03-26 23:46:31 +00:00 committed by Sam Lantinga
parent 9d294f1fca
commit 3f25704592
1 changed files with 2 additions and 2 deletions

View File

@ -54,9 +54,9 @@ main(int argc, char *argv[])
int success;
Uint64 seed = 0;
if (argv[1][0] == '0' && argv[1][1] == 'x')
success = SDL_sscanf(argv[1] + 2, "%llx", &seed);
success = SDL_sscanf(argv[1] + 2, "%"SDL_PRIx64, &seed);
else
success = SDL_sscanf(argv[1], "%llu", &seed);
success = SDL_sscanf(argv[1], "%"SDL_PRIu64, &seed);
if (!success) {
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Invalid seed. Use a decimal or hexadecimal number.\n");
return 1;