FAQ

On Thu, Apr 03, 2014 at 03:44:41PM -0700, Tony Cook via RT wrote:
Reproduced in blead:

[tonyc@dromedary-001 perl]$ ./perl -e 'my $x = " " x ((2**31 )-1); $x .="\n"; my $end = index($x, "\n", 0); print "END: $end\n"'
Segmentation fault
[tonyc@dromedary-001 perl]$ ./perl -v

This is perl 5, version 19, subversion 11 (v5.19.11 (v5.19.10-34-g6447043)) built for x86_64-linux-thread-multi
FWIW, I cannot reproduce this on 64-bit darwin:

$; perl -e 'my $x = " " x ((2**31 )-1); $x .="\n"; my $end = index($x, "\n", 0); print "END: $end\n"'
END: 2147483647

$; perl -v
This is perl 5, version 19, subversion 10 (v5.19.10) built for darwin-2level
$; uname -a
Darwin bourbon 12.5.0 Darwin Kernel Version 12.5.0: Sun Sep 29 13:33:47 PDT 2013; root:xnu-2050.48.12~1/RELEASE_X86_64 x86_64
$; perl -V | grep 32
$; perl -V | grep 64
     uname='darwin bourbon 12.5.0 darwin kernel version 12.5.0: sun sep 29 13:33:47 pdt 2013; root:xnu-2050.48.12~1release_x86_64 x86_64 '
     use64bitint=define, use64bitall=define, uselongdouble=undef
                         PERL_USE_DEVEL USE_64_BIT_ALL USE_64_BIT_INT

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 5 of 9 | next ›
Discussion Overview
groupperl5-porters @
categoriesperl
postedApr 2, '14 at 9:18a
activeApr 15, '14 at 2:01a
posts9
users4
websiteperl.org

People

Translate

site design / logo © 2021 Grokbase