[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]
Re: [ID 20000124.004] "perl in malloc(): warning: recursive call" on
On Tue, Jan 25, 2000 at 05:25:40PM -0500, Chuck Robey wrote:
> Do you know for a fact that perl, in the signal handler code, is not
> calling malloc?
$a = 0; # Prealloc the numeric slot;
$SIG{FOO} = sub { ++$a; return };
will not call malloc()/free()/realloc(). [At least around 5.004].
But this is easy to check. Before the programs starts to recieve
signals, let it make call some obscure function. I usually do
binmode STDERR;
or some such. Set breakpoint in Perl_pp_binmode. When hit (this way
all the hard memory-allocation part is already done, so you will not
get false positives), set breakpoints in malloc, free, realloc, and
Perl_sighandler. Watch your results (continue after each breakpoint).
Ilya
- References to:
-
Ilya Zakharevich <ilya@math.ohio-state.edu>
Chuck Robey <chuckr@picnic.mat.net>
[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]