This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
fix for [perl #66108] Leaked scalars
authorDavid Mitchell <davem@iabyn.com>
Fri, 8 Jan 2010 23:31:45 +0000 (23:31 +0000)
committerDavid Mitchell <davem@iabyn.com>
Fri, 8 Jan 2010 23:31:45 +0000 (23:31 +0000)
commit7fa38291524c327a3cb23bfe94979e1537743cac
tree7ff2b6956857090143401e5229b0edf770bf526e
parent4149198fba64273f3fea8fc073ccb5d080059f4a
fix for [perl #66108] Leaked scalars

@DB::args is a hack: it gets set with non-refcounted aliases of the
caller's @_ elements.

Once the sub that ran caller() has exited, @DB::args will contain garbage:
elements will be SVs that have been freed, re-assigned etc.

So as a minimum, when cloning an interpreter, skip cloning @DB::args.
sv.c