diff options
| author | Nathan Moinvaziri <nathan@nathanm.com> | 2020-07-10 13:59:25 -0700 |
|---|---|---|
| committer | Hans Kristian Rosbach <hk-github@circlestorm.org> | 2020-07-12 12:30:07 +0200 |
| commit | aac87a0762efb6d4c01c17a11701e4a8125541cc (patch) | |
| tree | fd135b731706c944a2b56d62c7ee0d51cbb9933f /test/fuzz | |
| parent | 4680bccb98c2871fecb42fca4ff050b63036d21d (diff) | |
| download | Project-Tick-aac87a0762efb6d4c01c17a11701e4a8125541cc.tar.gz Project-Tick-aac87a0762efb6d4c01c17a11701e4a8125541cc.zip | |
Removed legacy typedef caddr_t from gz_compress_mmap.
Diffstat (limited to 'test/fuzz')
| -rw-r--r-- | test/fuzz/minigzip_fuzzer.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/fuzz/minigzip_fuzzer.c b/test/fuzz/minigzip_fuzzer.c index e2ac6f7b17..a4bd112d3d 100644 --- a/test/fuzz/minigzip_fuzzer.c +++ b/test/fuzz/minigzip_fuzzer.c @@ -121,7 +121,7 @@ int gz_compress_mmap(FILE *in, gzFile out) { int len; int err; int ifd = fileno(in); - caddr_t buf; /* mmap'ed buffer for the entire input file */ + char *buf; /* mmap'ed buffer for the entire input file */ off_t buf_len; /* length of the input file */ struct stat sb; @@ -131,8 +131,8 @@ int gz_compress_mmap(FILE *in, gzFile out) { if (buf_len <= 0) return Z_ERRNO; /* Now do the actual mmap: */ - buf = mmap((caddr_t) 0, buf_len, PROT_READ, MAP_SHARED, ifd, (off_t)0); - if (buf == (caddr_t)(-1)) return Z_ERRNO; + buf = mmap((void *)0, buf_len, PROT_READ, MAP_SHARED, ifd, (off_t)0); + if (buf == (char *)(-1)) return Z_ERRNO; /* Compress the whole file at once: */ len = PREFIX(gzwrite)(out, (char *)buf, (unsigned)buf_len); |
