From: Gurusamy Sarathy Date: Wed, 4 Nov 1998 23:48:53 +0000 (+0000) Subject: indeterminate order-of-evaluation fixes X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=379c4362c2261464f61a477ba8cb859a7054e261;p=p5sagit%2Fp5-mst-13.2.git indeterminate order-of-evaluation fixes p4raw-id: //depot/perl@2192 --- diff --git a/mg.c b/mg.c index 743ee4a..6b5cb4f 100644 --- a/mg.c +++ b/mg.c @@ -1949,7 +1949,10 @@ magic_set(SV *sv, MAGIC *mg) || PL_origargv[i] == s + 2 #endif ) - s += strlen(++s); /* this one is ok too */ + { + ++s; + s += strlen(s); /* this one is ok too */ + } else break; } @@ -1962,8 +1965,10 @@ magic_set(SV *sv, MAGIC *mg) my_setenv("NoNe SuCh", Nullch); /* force copy of environment */ for (i = 0; PL_origenviron[i]; i++) - if (PL_origenviron[i] == s + 1) - s += strlen(++s); + if (PL_origenviron[i] == s + 1) { + ++s; + s += strlen(s); + } else break; }