Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: "double free or corruption" in Perl 5.16.0 but not in 5.14.2

by Khen1950fx (Canon)
on Sep 21, 2012 at 03:22 UTC ( #994801=note: print w/replies, xml ) Need Help??

in reply to "double free or corruption" in Perl 5.16.0 but not in 5.14.2

I couldn't replicate your problem, tested on 5.8x thru 5.17.4. At first, I thought the problem was with File::Glob; however, I kept getting an exception with chdir. It seems that there's a portability issue. I don't have fchdir, so I can't pass it a filehandle nor dirhandle without getting
chdir('') has been deprecated...
I stopped after this:
#!perl -l BEGIN { $| = 1; } use autodie; use strict 'refs'; use warnings FATAL => 'syntax'; use Data::Dumper::Concise; use File::Glob ':globally'; use Memoize; memoize('no_bug', LIST_CACHE => 'MEMORY'); no_bug(); sub no_bug { my(@md) = (1..305); my(@mp) = (1000..1205); print "market detail: ", scalar(@md); print "market price: ", scalar(@mp); my $path = '/tmp/xx'; foreach my $md(@md) { &open(my $f, '<', $path); &close($f); } foreach my $mp(@mp) { &open(my $f, '<', $path); &close($f); } chdir '/tmp/xx'; my(@sources) = <~$path/mp_*>, <~$path/md_* >; print Dumper(scalar @sources); }

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://994801]
[Corion]: Hi all ;)
[marto]: hey Corion, how's tricks?
[Corion]: marto: Currently all well - work is even OK currently ;) I should start translating my WWW::Mechanize:: Chrome talk to English and recheck that my demos all work, but I have two weeks for that still :)
[Corion]: So, most things are looking good :-D

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (9)
As of 2017-07-26 10:43 GMT
Find Nodes?
    Voting Booth?
    I came, I saw, I ...

    Results (390 votes). Check out past polls.