This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Re: [perl #54566] assertion failure fiddling with @ISA
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Wed, 21 May 2008 14:42:48 +0000 (16:42 +0200)
committerH.Merijn Brand <h.m.brand@xs4all.nl>
Wed, 21 May 2008 13:00:13 +0000 (13:00 +0000)
From: "Rafael Garcia-Suarez" <rgarciasuarez@gmail.com>
Message-ID: <b77c1dce0805210542l164caf85k86a34feae25ca9a7@mail.gmail.com>

p4raw-id: //depot/perl@33898

mg.c

diff --git a/mg.c b/mg.c
index f3e6ae9..6012d32 100644 (file)
--- a/mg.c
+++ b/mg.c
@@ -1583,7 +1583,7 @@ Perl_magic_setisa(pTHX_ SV *sv, MAGIC *mg)
     stash = GvSTASH(
         SvTYPE(mg->mg_obj) == SVt_PVGV
             ? (GV*)mg->mg_obj
-            : (GV*)SvMAGIC(mg->mg_obj)->mg_obj
+            : (GV*)mg_find(mg->mg_obj, PERL_MAGIC_isa)->mg_obj
     );
 
     if (stash)
@@ -1609,7 +1609,7 @@ Perl_magic_clearisa(pTHX_ SV *sv, MAGIC *mg)
     stash = GvSTASH(
         SvTYPE(mg->mg_obj) == SVt_PVGV
             ? (GV*)mg->mg_obj
-            : (GV*)SvMAGIC(mg->mg_obj)->mg_obj
+            : (GV*)mg_find(mg->mg_obj, PERL_MAGIC_isa)->mg_obj
     );
 
     if (stash)