diff options
author | David Mitchell <davem@iabyn.com> | 2010-12-16 16:14:06 +0000 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2010-12-16 16:16:14 +0000 |
commit | 93d7320bf7eac5942274854396d4ccc6268106c7 (patch) | |
tree | 279988fd2159c2ea009a71d79d668d18a1f43228 /sv.c | |
parent | 2cf724d498600d69eef0cc9013134e35fd9eff6d (diff) | |
download | perl-93d7320bf7eac5942274854396d4ccc6268106c7.tar.gz |
only call amagic_deref_call() if we have to
Diffstat (limited to 'sv.c')
-rw-r--r-- | sv.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -8812,7 +8812,8 @@ Perl_sv_2cv(pTHX_ SV *sv, HV **const st, GV **const gvp, const I32 lref) default: if (SvROK(sv)) { SvGETMAGIC(sv); - sv = amagic_deref_call(sv, to_cv_amg); + if (SvAMAGIC(sv)) + sv = amagic_deref_call(sv, to_cv_amg); /* At this point I'd like to do SPAGAIN, but really I need to force it upon my callers. Hmmm. This is a mess... */ |