From: Jarkko Hietaniemi Date: Mon, 7 Apr 2003 19:25:39 +0000 (+0000) Subject: The SvGROW() might move the PV. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d5a15ac20b88745ab30b67e8201632b6f5e6a04c;p=p5sagit%2Fp5-mst-13.2.git The SvGROW() might move the PV. p4raw-id: //depot/perl@19163 --- diff --git a/pp.c b/pp.c index 1bbe895..fde8b12 100644 --- a/pp.c +++ b/pp.c @@ -3387,7 +3387,8 @@ PP(pp_chr) tmps = SvPVX(TARG); if (SvCUR(TARG) == 0 || !is_utf8_string((U8*)tmps, SvCUR(TARG)) || memEQ(tmps, "\xef\xbf\xbd\0", 4)) { - SvGROW(TARG,3); + SvGROW(TARG, 3); + tmps = SvPVX(TARG); SvCUR_set(TARG, 2); *tmps++ = (U8)UTF8_EIGHT_BIT_HI(value); *tmps++ = (U8)UTF8_EIGHT_BIT_LO(value);