WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] libxc: lzma build fix

Ian Campbell writes ("Re: [Xen-devel] [PATCH] libxc: lzma build fix"):
> Putting aside the fact that 128MB is a quite obscene amount of memory as
> a _minimum_ requirement for something like this I guess we should change
> the constant.

I have done so.

Ian.

# HG changeset patch
# User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
# Date 1297446553 0
# Node ID 4376c4f0196f0dc129904a0f8c54c74ae4bcdff2
# Parent  6c22ae0f654084a4d2811e51e22b7f8b20b49cec
libxc: increase lzma max memory constant to 128Mby

According to lzma's configure.ac (!) the minimum memory limit to cope
with arbitrary input is 128Mby (!)

This is obviously an unreasonable amount of memory for this kind of
task, but we need to increase the constant limit for it not to
randomly fail.  So do so.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>

diff -r 6c22ae0f6540 -r 4376c4f0196f tools/libxc/xc_dom_bzimageloader.c
--- a/tools/libxc/xc_dom_bzimageloader.c        Fri Feb 11 16:51:44 2011 +0000
+++ b/tools/libxc/xc_dom_bzimageloader.c        Fri Feb 11 17:49:13 2011 +0000
@@ -152,7 +152,7 @@ static int xc_try_lzma_decode(
     int outsize;
     const char *msg;
 
-    ret = lzma_alone_decoder(&stream, 32*1024*1024);
+    ret = lzma_alone_decoder(&stream, 128*1024*1024);
     if ( ret != LZMA_OK )
     {
         DOMPRINTF("LZMA: Failed to init stream decoder");

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>