projects
/
platform
/
upstream
/
perl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6eea2b4
)
Don’t double-free GVs in gv:S_maybe_add_coresub
author
Father Chrysostomos
<sprout@cpan.org>
Sun, 1 Jan 2012 22:19:54 +0000
(14:19 -0800)
committer
Father Chrysostomos
<sprout@cpan.org>
Sun, 1 Jan 2012 22:19:54 +0000
(14:19 -0800)
Commit
8756617677
did not take into account that newSVOP steals a ref-
erence count.
gv.c
patch
|
blob
|
history
diff --git
a/gv.c
b/gv.c
index
3005895
..
df3735a
100644
(file)
--- a/
gv.c
+++ b/
gv.c
@@
-517,7
+517,7
@@
S_maybe_add_coresub(pTHX_ HV * const stash, GV *gv,
if (ampable) {
CvLVALUE_on(cv);
newATTRSUB(oldsavestack_ix,
- newSVOP(OP_CONST, 0,
(SV *)gv
),
+ newSVOP(OP_CONST, 0,
SvREFCNT_inc_simple_NN(gv)
),
NULL,NULL,
coresub_op(
opnum