summaryrefslogtreecommitdiff
path: root/sv.c
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1998-07-18 04:23:12 +0000
committerGurusamy Sarathy <gsar@cpan.org>1998-07-18 04:23:12 +0000
commit02270b4e1187bc8d0def222ae3fb78581e1dc745 (patch)
tree3af6b9b70ffcbab12320fd78f064ea03a0b34a6c /sv.c
parent5c7a8c7888175e16e13670318410610dcb21c26f (diff)
downloadperl-02270b4e1187bc8d0def222ae3fb78581e1dc745.tar.gz
fix lvalue leaks stemming from failure to free LvTARG(sv)
p4raw-id: //depot/perl@1528
Diffstat (limited to 'sv.c')
-rw-r--r--sv.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sv.c b/sv.c
index 46b51a344f..29c45fd37a 100644
--- a/sv.c
+++ b/sv.c
@@ -2905,6 +2905,9 @@ sv_clear(register SV *sv)
case SVt_PVAV:
av_undef((AV*)sv);
break;
+ case SVt_PVLV:
+ SvREFCNT_dec(LvTARG(sv));
+ goto freescalar;
case SVt_PVGV:
gp_free((GV*)sv);
Safefree(GvNAME(sv));
@@ -2914,7 +2917,6 @@ sv_clear(register SV *sv)
-- JohnPC, 27 Mar 1998 */
stash = GvSTASH(sv);
/* FALL THROUGH */
- case SVt_PVLV:
case SVt_PVMG:
case SVt_PVNV:
case SVt_PVIV: