findsubname(), explicit break out of the loop

This commit is contained in:
rlar 2017-11-22 22:34:22 +01:00
parent cbd38fdc9c
commit 01eb593ca4
1 changed files with 4 additions and 1 deletions

View File

@ -169,13 +169,16 @@ findsubname(dico_t *dico, SPICE_DSTRINGPTR dstr_p)
int nest = 1;
p--;
while ((nest > 0) && (p > s)) {
while (p > s) {
if (p[-1] == '{')
nest--;
else if (p[-1] == '}')
nest++;
p--;
if (nest <= 0) {
break;
}
}
p_end = p; /* p_end points to '{' */