Perl: the Markov chain saw | |
PerlMonks |
Re^10: Segfault on second (identical) call to a subby BrowserUk (Patriarch) |
on Feb 07, 2006 at 04:53 UTC ( [id://528418]=note: print w/replies, xml ) | Need Help?? |
First. Many thanks for having continued to pursue this. Above and beyond. but afaict there is something not right with GD-2.30, either I was reaching a similar conclusion myself--and it doesn't appear to be limited to 2.30 (which I have yet have pass it's own testsuite so I haven't installed it). Having reverted to 5.8.6, I find that GD 2.28 also produces this error there, though I have to exercise it harder, (loop more times), before it occurs. If I hadn't seen the error several times with other, non-GD, non-threads code since I upgraded to 5.8.7, I would've been more inclined to point the finger at GD despite the authorship. I am a neophyte as far as XS is concerned. However, I think I may have cracked it?
See HERE! above. I made this change and (on very first blush), it appears to fix the problem with my OP code and the original from which it is derived. If I understand the above correctly, data is just a pointer to a part of an SV that I pass in, so the library should not be freeing it? It should leave it intact until the SV get gc'd in the normal way? Does that make sense to you? If correct, then the newFromGD2Data() call is similarly affected, but not any of the others (png/jpeg/WBMP) as they do not free the data passed in. Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
In Section
Seekers of Perl Wisdom
|
|