GNU bug report logs - #43999
sed: couldn't re-allocate memory

Previous Next

Package: sed;

Reported by: markfilipak.linux+gnuorg <at> gmail.com

Date: Wed, 14 Oct 2020 21:54:02 UTC

Severity: normal

Tags: moreinfo

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Mark Filipak <markfilipak <at> neo.rr.com>
To: bug-sed <at> gnu.org
Subject: sed: couldn't re-allocate memory
Date: Wed, 14 Oct 2020 16:40:42 -0400
Kindly expedite this and contact me for any reason.

The file "1,073,709,056 bytes" provokes an error (& zero output), but only if piped from 'tr' and 
only for a particular pattern: /00000100/.
the file "1,073,739,776 bytes" succeeds with identical parameters.
The pipe through 'tr' appears not to be the problem.

$ sed --version
sed (GNU sed) 4.2.2
...
$ xxd -p -u "1,073,709,056 bytes" | tr -d '\n' | sed -r 's/00000100/\x0D\x0A&/g' > foo.txt
sed: couldn't re-allocate memory
$ xxd -p -u "1,073,709,056 bytes" | tr -d '\n' | sed -r 's/000001/\x0D\x0A&/g' > foo.txt
$ xxd -p -u "1,073,709,056 bytes" | sed -r 's/00000100/\x0D\x0A&/g' > foo.txt
$ xxd -p -u "1,073,739,776 bytes" | tr -d '\n' | sed -r 's/00000100/\x0D\x0A&/g' > foo.txt
$

You probably want the two source files, or perhaps only the source file that provokes the error. 
Kindly let me know how I can send it to you.

Regards,
Mark Filipak.

PS: For your sake, I posted a request for vetting this case
https://forums.linuxmint.com/viewtopic.php?f=47&t=332836
I got no responses, so it has not been replicated by someone else.




This bug report was last modified 4 years and 244 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.