I am trying to use 'xz -9' to compress a file, but the programme exits
with the error message 'Cannot allocate memory'. Here's what I tried:
$ echo Hello World > compress_me.txt
$ xz -9 compress_me.txt
xz: compress_me.txt: Cannot allocate memory
$ xz --version
xz (XZ Utils) 5.0.2
liblzma 5.0.2
Having read http://cygwin.com/cygwin-ug-net/setup-maxmem.html I tried
the following:
$ peflags --cygwin-heap /usr/bin/xz.exe
/usr/bin/xz.exe: initial Cygwin heap size: 0 (0x0) MB
$ peflags --cygwin-heap=1024 /usr/bin/xz.exe
/usr/bin/xz.exe: initial Cygwin heap size: 1024 (0x400) MB
$ xz -9 compress_me.txt
And this worked. Is this the correct way to fix the problem? If so,
please could we increment the heap size for xz in a post install script?
Many thanks,
Dave.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple