It's just used as a temporary value in two branches;
so make it a local var in each of those branches.
char *strend;
char *m;
const char *c;
- char *d;
STRLEN clen;
I32 iters = 0;
I32 maxiters;
orig = SvPV_force_nomg(TARG, len);
goto force_it;
}
- d = s;
+
if (once) {
+ char *d;
if (RX_MATCH_TAINTED(rx)) /* run time pattern taint, eg locale */
rxtainted |= SUBST_TAINT_PAT;
m = orig + RX_OFFS(rx)[0].start;
PUSHs(&PL_sv_yes);
}
else {
+ char *d = s;
do {
if (iters++ > maxiters)
DIE(aTHX_ "Substitution loop");