summaryrefslogtreecommitdiff
path: root/hv.c
diff options
context:
space:
mode:
Diffstat (limited to 'hv.c')
-rw-r--r--hv.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hv.c b/hv.c
index e245198288..634e6809ef 100644
--- a/hv.c
+++ b/hv.c
@@ -1729,8 +1729,8 @@ Perl_hv_undef(pTHX_ HV *hv)
hfreeentries(hv);
Safefree(xhv->xhv_array /* HvARRAY(hv) */);
if (HvNAME(hv)) {
- if(PL_stashcache)
- hv_delete_ent(PL_stashcache, sv_2mortal(newSVpv(HvNAME(hv),0)), G_DISCARD, 0);
+ if(PL_stashcache)
+ hv_delete(PL_stashcache, HvNAME(hv), strlen(HvNAME(hv)), G_DISCARD);
Safefree(HvNAME(hv));
HvNAME(hv) = 0;
}