diff options
author | Mike Frysinger <vapier@gentoo.org> | 2021-04-24 14:40:43 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2021-05-14 21:16:40 -0400 |
commit | 2fbe9507bfba58a6a000d231fe735bad1f245b55 (patch) | |
tree | 8b4709489be830480eae1d98a37b2df8af5d60d1 /sim/common/callback.c | |
parent | 00330cd18a4ba83beabad4cb9f4215170828cd29 (diff) | |
download | gdb-2fbe9507bfba58a6a000d231fe735bad1f245b55.zip gdb-2fbe9507bfba58a6a000d231fe735bad1f245b55.tar.gz gdb-2fbe9507bfba58a6a000d231fe735bad1f245b55.tar.bz2 |
sim: callback: convert FS interfaces to 64-bit
Rather than rely on off_t being the right size between the host &
target, have the interface always be 64-bit. We can figure out if
we need to truncate when actually outputting it to the right target.
Diffstat (limited to 'sim/common/callback.c')
-rw-r--r-- | sim/common/callback.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sim/common/callback.c b/sim/common/callback.c index fb5e864..24ea470 100644 --- a/sim/common/callback.c +++ b/sim/common/callback.c @@ -205,10 +205,10 @@ os_isatty (host_callback *p, int fd) return result; } -static int -os_lseek (host_callback *p, int fd, long off, int way) +static int64_t +os_lseek (host_callback *p, int fd, int64_t off, int way) { - int result; + int64_t result; result = fdbad (p, fd); if (result) @@ -519,7 +519,7 @@ os_lstat (host_callback *p, const char *file, struct stat *buf) } static int -os_ftruncate (host_callback *p, int fd, long len) +os_ftruncate (host_callback *p, int fd, int64_t len) { int result; @@ -542,7 +542,7 @@ os_ftruncate (host_callback *p, int fd, long len) } static int -os_truncate (host_callback *p, const char *file, long len) +os_truncate (host_callback *p, const char *file, int64_t len) { #ifdef HAVE_TRUNCATE int result; |