mirror of
https://github.com/mdbtools/mdbtools.git
synced 2025-04-05 20:31:00 +08:00
More printf portability fixes
This commit is contained in:
parent
446b92b2c8
commit
9941cb2927
@ -372,7 +372,7 @@ static ssize_t _mdb_read_pg(MdbHandle *mdb, void *pg_buf, unsigned long pg)
|
||||
|
||||
fstat(mdb->f->fd, &status);
|
||||
if (status.st_size < offset) {
|
||||
fprintf(stderr,"offset %lld is beyond EOF\n",(long long)offset);
|
||||
fprintf(stderr,"offset %" PRIu64 " is beyond EOF\n",(uint64_t)offset);
|
||||
return 0;
|
||||
}
|
||||
if (mdb->stats && mdb->stats->collect)
|
||||
|
@ -81,7 +81,7 @@ mdb_write_pg(MdbHandle *mdb, unsigned long pg)
|
||||
fstat(mdb->f->fd, &status);
|
||||
/* is page beyond current size + 1 ? */
|
||||
if (status.st_size < offset + mdb->fmt->pg_size) {
|
||||
fprintf(stderr,"offset %lld is beyond EOF\n",(long long)offset);
|
||||
fprintf(stderr,"offset %" PRIu64 " is beyond EOF\n",(uint64_t)offset);
|
||||
return 0;
|
||||
}
|
||||
lseek(mdb->f->fd, offset, SEEK_SET);
|
||||
|
Loading…
Reference in New Issue
Block a user