wiretap: fix a warning on Raspberry 4

/home/pi/wireshark/wiretap/file_wrappers.c: In function ‘file_fdopen’:
/home/pi/wireshark/wiretap/file_wrappers.c:1136:27: error: comparison of integer expressions of different signedness: ‘__blksize_t’ {aka ‘long int’} and ‘unsigned int’ [-Werror=sign-compare]
         if (st.st_blksize <= MAX_READ_BUF_SIZE)
                           ^~
cc1: all warnings being treated as errors
This commit is contained in:
Nardi Ivan 2021-10-18 18:39:07 +02:00 committed by Guy Harris
parent d8742418aa
commit a2e877d397
1 changed files with 1 additions and 1 deletions

View File

@ -1133,7 +1133,7 @@ file_fdopen(int fd)
* If the value is too big to fit into a guint,
* just use the maximum read buffer size.
*/
if (st.st_blksize <= MAX_READ_BUF_SIZE)
if (st.st_blksize <= (long)MAX_READ_BUF_SIZE)
want = (guint)st.st_blksize;
else
want = MAX_READ_BUF_SIZE;