summaryrefslogtreecommitdiff
path: root/hv.c
diff options
context:
space:
mode:
Diffstat (limited to 'hv.c')
-rw-r--r--hv.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hv.c b/hv.c
index 08867cf5d0..808a4bf9a3 100644
--- a/hv.c
+++ b/hv.c
@@ -692,6 +692,7 @@ Perl_hv_common(pTHX_ HV *hv, SV *keysv, const char *key, STRLEN klen,
}
HeVAL(entry) = val;
} else if (action & HV_FETCH_ISSTORE) {
+ SvREFCNT_dec(HeVAL(entry));
HeVAL(entry) = val;
}
} else if (HeVAL(entry) == &PL_sv_placeholder) {