If the error references the first token and there is no preceding
newline we would core dump.
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3257
d4fa192b-c00b-0410-8231-
f00ffab90ce4
pos = 0;
sp = t->src;
b = sp->b;
+ if (ll != NULL)
+ *ll = b;
for (p = b; p < t->b; p++) {
if (*p == '\n') {
lin++;
for (q = p + 2; q < sp->e; q++) {
if (*q == '}' && q[1] == 'C') {
vcc_AddToken(tl, CSRC, p, q + 2);
- p = q + 2;
break;
}
}
- if (q < sp->e)
+ if (q < sp->e) {
+ p = q + 2;
continue;
+ }
vcc_AddToken(tl, EOI, p, p + 2);
vsb_printf(tl->sb,
"Unterminated inline C source, starting at\n");