From d57c858ad3d44375705c397ed199f6284061e9f6 Mon Sep 17 00:00:00 2001 From: Timo Strunk Date: Fri, 12 Sep 2014 22:04:37 +0200 Subject: [PATCH] size_t to ssize_t because otherwise the errorvalue would be wrong, because of the cast to unsigned. --- decompress/zip_support.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/decompress/zip_support.c b/decompress/zip_support.c index 2da2f64d44..5730dc7693 100644 --- a/decompress/zip_support.c +++ b/decompress/zip_support.c @@ -33,7 +33,7 @@ */ int read_zip_file(const char * archive_path, const char *relative_path, void **buf) { - size_t bytes_read = -1; + ssize_t bytes_read = -1; bool finished_reading = false; unzFile *zipfile = (unzFile*)unzOpen( archive_path ); if ( ! zipfile ) @@ -144,7 +144,7 @@ struct string_list *compressed_zip_file_list_new(const char *path, ext_list = string_split(ext, "|"); - size_t bytes_read = -1; + ssize_t bytes_read = -1; bool finished_reading = false; unzFile *zipfile = (unzFile*)unzOpen( path );