mirror of
https://git.code.sf.net/p/quake/quake2forge
synced 2025-04-04 16:31:05 +00:00
- Use printf's z modifier for printing size_t types, fixes
build failure on 64 bit architectures. Thanks to Juhana Paavola for reporting the problem. (Closes: #72)
This commit is contained in:
parent
1180ade5be
commit
759f9efeff
2 changed files with 3 additions and 2 deletions
1
THANKS
1
THANKS
|
@ -25,6 +25,7 @@ Ragnvald Maartman-Moe IV <despair@quakeforge.net>
|
|||
Elias Mårtensson <@sun.com>
|
||||
Brady McCary <mccary@tamu.edu>
|
||||
Faried Nawaz <fn@hungry.org>
|
||||
Juhana Paavola <jupaavol@ratol.fi>
|
||||
'RvB' <hansmaulwurf@blinkenlights.ch>
|
||||
Victor Shkamerda <vvs@auto.bnm.org>
|
||||
Jean-François St-Amour <jfs@videotron.ca>
|
||||
|
|
|
@ -527,7 +527,7 @@ size_t verify_fread(void * ptr, size_t size, size_t nitems, FILE * fp) {
|
|||
ret = fread(ptr, size, nitems, fp);
|
||||
err = errno;
|
||||
if (ret != nitems) {
|
||||
printf("verify_fread(...,%d,%d,...): return value: %d\n", size, nitems, ret);
|
||||
printf("verify_fread(...,%zd,%zd,...): return value: %zd\n", size, nitems, ret);
|
||||
if (ret == 0 && ferror(fp)) {
|
||||
printf(" error: %s\n", strerror(err));
|
||||
printf(" fileno=%d\n", fileno(fp));
|
||||
|
@ -545,7 +545,7 @@ size_t verify_fwrite(void * ptr, size_t size, size_t nitems, FILE * fp) {
|
|||
ret = fwrite(ptr, size, nitems, fp);
|
||||
err = errno;
|
||||
if (ret != nitems) {
|
||||
printf("verify_fwrite(...,%d,%d,...) = %d\n", size, nitems, ret);
|
||||
printf("verify_fwrite(...,%zd,%zd,...) = %zd\n", size, nitems, ret);
|
||||
if (ret == 0 && ferror(fp)) {
|
||||
printf(" error: %s\n", strerror(err));
|
||||
printf(" fileno=%d\n", fileno(fp));
|
||||
|
|
Loading…
Reference in a new issue