psss / rpms / libguestfs

Forked from rpms/libguestfs 5 years ago
Clone
Blob Blame History Raw
From d1f9407a92ba3bec2e1efe1b3ba0544358e5d6be Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Thu, 13 Feb 2014 17:48:06 +0000
Subject: [PATCH] builder: pxzcat: Fix char * signedness warning.

(cherry picked from commit e4fe09c5ae28ee34d87bceecf58f72cc43af6249)
---
 builder/pxzcat-c.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/builder/pxzcat-c.c b/builder/pxzcat-c.c
index 5ffc9d9..06d46fc 100644
--- a/builder/pxzcat-c.c
+++ b/builder/pxzcat-c.c
@@ -381,7 +381,7 @@ parse_indexes (value filenamev, int fd)
  * http://stackoverflow.com/questions/1493936/faster-means-of-checking-for-an-empty-buffer-in-c/1493989#1493989
  */
 static inline int
-is_zero (const char *buffer, size_t size)
+is_zero (const unsigned char *buffer, size_t size)
 {
   size_t i;
 
@@ -489,7 +489,7 @@ worker_thread (void *vp)
   lzma_ret r;
   lzma_stream strm = LZMA_STREAM_INIT;
   uint8_t buf[BUFFER_SIZE];
-  char outbuf[BUFFER_SIZE];
+  unsigned char outbuf[BUFFER_SIZE];
   size_t i;
   lzma_bool iter_finished;
 
-- 
1.8.5.3