aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/decompress_inflate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/decompress_inflate.c b/lib/decompress_inflate.c
index 19ff89e34eec..d619b28c456f 100644
--- a/lib/decompress_inflate.c
+++ b/lib/decompress_inflate.c
@@ -48,7 +48,7 @@ STATIC int INIT gunzip(unsigned char *buf, int len,
48 out_len = 0x8000; /* 32 K */ 48 out_len = 0x8000; /* 32 K */
49 out_buf = malloc(out_len); 49 out_buf = malloc(out_len);
50 } else { 50 } else {
51 out_len = 0x7fffffff; /* no limit */ 51 out_len = ((size_t)~0) - (size_t)out_buf; /* no limit */
52 } 52 }
53 if (!out_buf) { 53 if (!out_buf) {
54 error("Out of memory while allocating output buffer"); 54 error("Out of memory while allocating output buffer");