Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: The number of ways I've independently discovered to make Perl segfault:

by scrottie (Scribe)
on Sep 28, 2003 at 12:16 UTC ( #294735=note: print w/replies, xml ) Need Help??


in reply to The number of ways I've independently discovered to make Perl segfault:

sub f { my $x = shift; *z = $x; } f({}); f();
Dave Mitchell solved this within a week and gave this description: "the second call to f() has $x as type RV (due to the previous call), but !ROK - due to the undef assignment. sv_setsv_flags() didn't check for ROK in this context." This was discovered while writing Object::Lexical. It stuffs closures into a stash created to represent an object - each object is its own blessed stash. I assumed (incorrectly) that the problem had something to do with blessing stashes. The fix is in 5.8.1. Hats off to the Perl 5 Porters! You guys rock! -scott
  • Comment on Re: The number of ways I've independently discovered to make Perl segfault:
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://294735]
help
Chatterbox?
[dazz]: Hi I have grabbed an image from an IP camera with Image::Grab. I then want to pass that image object to a subroutine where I do a read-only test on the image with Image:Magick.
[dazz]: How do I pass an image object to a subroutine and then apply a Image::Magick a read-only method to the image object???

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (7)
As of 2017-03-27 07:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (317 votes). Check out past polls.