mirror of
https://github.com/cuberite/libdeflate.git
synced 2025-08-04 02:06:31 -04:00
prog_util: make it clear that posix_[fm]advise errors are ignored
This commit is contained in:
parent
ea2f7569b0
commit
fbada10aa9
@ -186,7 +186,7 @@ xopen_for_read(const tchar *path, bool symlink_ok, struct file_stream *strm)
|
||||
}
|
||||
|
||||
#if defined(HAVE_POSIX_FADVISE) && (O_SEQUENTIAL == 0)
|
||||
posix_fadvise(strm->fd, 0, 0, POSIX_FADV_SEQUENTIAL);
|
||||
(void)posix_fadvise(strm->fd, 0, 0, POSIX_FADV_SEQUENTIAL);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
@ -347,7 +347,7 @@ map_file_contents(struct file_stream *strm, u64 size)
|
||||
}
|
||||
|
||||
#ifdef HAVE_POSIX_MADVISE
|
||||
posix_madvise(strm->mmap_mem, size, POSIX_MADV_SEQUENTIAL);
|
||||
(void)posix_madvise(strm->mmap_mem, size, POSIX_MADV_SEQUENTIAL);
|
||||
#endif
|
||||
strm->mmap_token = strm; /* anything that's not NULL */
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user