From: erg Date: Mon, 6 Dec 2010 18:35:24 +0000 (+0000) Subject: Fix bug in scanner. We weren't handling escaped backslashes. X-Git-Tag: LAST_LIBGRAPH~32^2~1132 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ef190f79d15b43256ad2ef901103835fc3e5d675;p=graphviz Fix bug in scanner. We weren't handling escaped backslashes. --- diff --git a/lib/cgraph/scan.l b/lib/cgraph/scan.l index ed4cc20ad..8d5866330 100644 --- a/lib/cgraph/scan.l +++ b/lib/cgraph/scan.l @@ -182,6 +182,7 @@ ID ({NAME}|{NUMBER}) ["] BEGIN(qstring); beginstr(); ["] BEGIN(INITIAL); endstr(); return (T_qatom); [\\]["] addstr ("\""); +[\\][\\] addstr ("\\"); [\\][\n] line_num++; /* ignore escaped newlines */ ([^"\\]*|[\\]) addstr(yytext); [<] BEGIN(hstring); html_nest = 1; beginstr();