Do you know where your variables are? | |
PerlMonks |
Re: Propagating errors in C code to Perlby betterworld (Curate) |
on Sep 05, 2008 at 13:42 UTC ( [id://709273]=note: print w/replies, xml ) | Need Help?? |
Afaik you can die from C code using the "croak" function. Here's an example how to do it and set $@. Probably setting $! works If you throw exceptions from C code, you just have to make sure that all your dynamically allocated memory is freed, which can be a problem in callbacks from external libraries.
In Section
Seekers of Perl Wisdom
|
|