the error path of VarModifiers_Apply(). This prevents a sporadic
crash in make's regress target t41.
OK espie@
-/* $OpenBSD: varmodifiers.c,v 1.46 2017/02/24 23:38:47 espie Exp $ */
+/* $OpenBSD: varmodifiers.c,v 1.47 2017/07/10 07:10:29 bluhm Exp $ */
/* $NetBSD: var.c,v 1.18 1997/03/18 19:24:46 christos Exp $ */
/*
} else {
Error("Bad modifier: %s", tstr);
/* Try skipping to end of var... */
- for (tstr++; *tstr != endc && *tstr != '\0';)
+ while (*tstr != endc && *tstr != '\0')
tstr++;
if (str != NULL && *freePtr)
free(str);