From 081a6af278fc2b4f33198e2ec0028f8383bb6d4a Mon Sep 17 00:00:00 2001 From: Kai Krakow Date: Sat, 19 Jun 2021 10:32:30 +0200 Subject: [PATCH] bees: Avoid unused result with -Werror=unused-result Fixes: commit 20b8f8ae0b392 ("bees: use helper function for readahead") Signed-off-by: Kai Krakow --- src/bees.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bees.cc b/src/bees.cc index 9bff140..979f914 100644 --- a/src/bees.cc +++ b/src/bees.cc @@ -241,7 +241,7 @@ bees_readahead(int const fd, off_t offset, size_t size) size_t this_read_size = min(size, sizeof(dummy)); // Ignore errors and short reads. // It turns out our size parameter isn't all that accurate. - pread(fd, dummy, this_read_size, offset); + (void)!pread(fd, dummy, this_read_size, offset); BEESCOUNT(readahead_count); BEESCOUNTADD(readahead_bytes, this_read_size); offset += this_read_size;