GNU bug report logs - #13258
bug in ln.

Previous Next

Package: coreutils;

Reported by: Joshua Rogers <megamansec <at> gmail.com>

Date: Sun, 23 Dec 2012 06:18:02 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 13258 in the body.
You can then email your comments to 13258 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-coreutils <at> gnu.org:
bug#13258; Package coreutils. (Sun, 23 Dec 2012 06:18:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Joshua Rogers <megamansec <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-coreutils <at> gnu.org. (Sun, 23 Dec 2012 06:18:02 GMT) Full text and rfc822 format available.

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

From: Joshua Rogers <megamansec <at> gmail.com>
To: bug-coreutils <at> gnu.org
Subject: bug in ln.
Date: Sun, 23 Dec 2012 15:40:01 +1100
[Message part 1 (text/plain, inline)]
ln bug.

$ gdb ln
GNU gdb (Ubuntu/Linaro 7.4-2012.04-0ubuntu2.1) 7.4-2012.04
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>...
Reading symbols from /bin/ln...(no debugging symbols found)...done.
(gdb) run `perl -e 'print "x"x(2**31)'` `perl -e 'print "x"x(2**30)'`
Starting program: /bin/ln `perl -e 'print "x"x(2**31)'` `perl -e 'print
"x"x(2**30)'`
/bin/bash: xrealloc: ../bash/subst.c:5179: cannot allocate
18446744071562067968 bytes (4295012352 bytes allocated)
During startup program exited with code 2.




Doing it without gdb, it just crashes the console.
Inside `screen` it crashes that one screen (say you have two "tabs" in
the screen, it only crashes the one tab)
Bug can be reproduced like this:
/bin/ln `perl -e 'print "x"x(2**31)'` `perl -e 'print "x"x(2**30)'`


K, thanks.


-- 
*Joshua Rogers* - Retro Game Collector && IT Security Specialist
gpg pubkey <http://www.internot.info/docs/gpg_pubkey.asc.gpg>
[Message part 2 (text/html, inline)]

Reply sent to Paul Eggert <eggert <at> cs.ucla.edu>:
You have taken responsibility. (Sun, 23 Dec 2012 17:35:02 GMT) Full text and rfc822 format available.

Notification sent to Joshua Rogers <megamansec <at> gmail.com>:
bug acknowledged by developer. (Sun, 23 Dec 2012 17:35:02 GMT) Full text and rfc822 format available.

Message #10 received at 13258-done <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: bug-bash <at> gnu.org
Cc: 13258-done <at> debbugs.gnu.org, Joshua Rogers <megamansec <at> gmail.com>
Subject: Bash loops and otherwise mishandles long lines
Date: Sun, 23 Dec 2012 09:34:18 -0800
Here's how to reproduce the problem:

(printf 'ln '
 perl -e 'print "x"x(2**31)'
 printf ' '
 perl -e 'print "x"x(2**30)'
 printf '\n'
) >bigscript
bash bigscript

On my x86-64 host, Bash loops, seemingly forever.
I expect it's using a 32-bit integer to keep track
of line lengths, somewhere.

This bug report was inspired by the following report:

http://debbugs.gnu.org/13258

That bug report is against coreutils, but the real
bug was in bash, so I'm closing bug 13258 and forwarding
this to bug-bash <at> gnu.org.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 21 Jan 2013 12:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 11 years and 95 days ago.

Previous Next


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