From: Rafael Garcia-Suarez Date: Mon, 7 Dec 2009 12:55:49 +0000 (+0100) Subject: Allocate the right HV X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=6bc991bfb3c34a5d286a1202fcc0d740d72dcee7;p=p5sagit%2Fp5-mst-13.2.git Allocate the right HV This will solve an obscure bug in smart-match involving nested data structures containing the same elements. --- diff --git a/pp_ctl.c b/pp_ctl.c index 68a42d7..b196640 100644 --- a/pp_ctl.c +++ b/pp_ctl.c @@ -4313,7 +4313,7 @@ S_do_smartmatch(pTHX_ HV *seen_this, HV *seen_other) (void) sv_2mortal(MUTABLE_SV(seen_this)); } if (NULL == seen_other) { - seen_this = newHV(); + seen_other = newHV(); (void) sv_2mortal(MUTABLE_SV(seen_other)); } for(i = 0; i <= other_len; ++i) {