]> git.ipfire.org Git - thirdparty/xz.git/commitdiff
extra/scanlzma: Fix compiler warnings.
authorLasse Collin <lasse.collin@tukaani.org>
Sun, 29 Apr 2018 15:48:00 +0000 (18:48 +0300)
committerLasse Collin <lasse.collin@tukaani.org>
Sun, 29 Apr 2018 15:48:00 +0000 (18:48 +0300)
extra/scanlzma/scanlzma.c

index 5c3b25be32acacf96f20e128e4c19c04e3defd3c..110f822b35d4172472076cf783750692fc5e1279 100644 (file)
 /*   5     8   Uncompressed size (little endian). -1 means unknown size */
 /*  13         Compressed data */
 
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+
 #define BUFSIZE 4096
 
 int find_lzma_header(unsigned char *buf) {
@@ -48,7 +52,7 @@ int find_lzma_header(unsigned char *buf) {
 }
 
 int main(int argc, char *argv[]) {
-       char buf[BUFSIZE];
+       unsigned char buf[BUFSIZE];
        int ret, i, numlzma, blocks=0;
 
        if (argc != 2) {