libbb: change gzip_read() buffer argument to void *
authorJo-Philipp Wich <jo@mein.io>
Tue, 14 Mar 2017 23:50:46 +0000 (00:50 +0100)
committerJo-Philipp Wich <jo@mein.io>
Wed, 15 Mar 2017 00:42:49 +0000 (01:42 +0100)
Make gzip_read() expect a void * buffer argument to avoid signed vs unsigned
char mismatch warnings.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
libbb/gzip.c
libbb/gzip.h

index dc3b2834aec212eb05be62973b5fdbff33a02173..622d617e9b3bf22acb23e102ba89cb0b772521d7 100644 (file)
@@ -130,7 +130,7 @@ int gzip_exec(struct gzip_handle *zh, const char *filename)
        return 0;
 }
 
        return 0;
 }
 
-ssize_t gzip_read(struct gzip_handle * zh, char *buf, ssize_t len)
+ssize_t gzip_read(struct gzip_handle * zh, void *buf, ssize_t len)
 {
        ssize_t ret;
 
 {
        ssize_t ret;
 
index 13398d407f9a5d7bcb3eb5e670ab2585a13d6082..3a61a1dce514ecc543cd6e69c60e1c23bd2c6aa4 100644 (file)
@@ -33,7 +33,7 @@ struct gzip_handle {
 };
 
 int gzip_exec(struct gzip_handle *zh, const char *filename);
 };
 
 int gzip_exec(struct gzip_handle *zh, const char *filename);
-ssize_t gzip_read(struct gzip_handle *zh, char *buf, ssize_t len);
+ssize_t gzip_read(struct gzip_handle *zh, void *buf, ssize_t len);
 ssize_t gzip_copy(struct gzip_handle *zh, FILE * out, ssize_t len);
 int gzip_close(struct gzip_handle *zh);
 FILE *gzip_fdopen(struct gzip_handle *zh, const char *filename);
 ssize_t gzip_copy(struct gzip_handle *zh, FILE * out, ssize_t len);
 int gzip_close(struct gzip_handle *zh);
 FILE *gzip_fdopen(struct gzip_handle *zh, const char *filename);