summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-gfx/graphviz/files/graphviz-2.38-fix-backslashes.patch')
-rw-r--r--media-gfx/graphviz/files/graphviz-2.38-fix-backslashes.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/media-gfx/graphviz/files/graphviz-2.38-fix-backslashes.patch b/media-gfx/graphviz/files/graphviz-2.38-fix-backslashes.patch
new file mode 100644
index 000000000000..b4e911de6a94
--- /dev/null
+++ b/media-gfx/graphviz/files/graphviz-2.38-fix-backslashes.patch
@@ -0,0 +1,34 @@
+User reported a regression between 2.26 and 2.36
+when trying to .dot the following graph:
+
+ digraph g {
+ 1 -> 2 [label="\\"]
+ }
+
+2.26 shows it as '\' while 2.36 fails as:
+ $ dot -Tpng a.dot -o a.png
+ Warning: 1.dot: syntax error in line 2 near ''
+
+Thanks to Ulya Trofimovich who found and bisected
+the problem down to this commit, which fixes problem
+only in git version.
+
+commit 386e47c14b3a8e83bdf3ec8772963213095a7294
+Author: Emden R. Gansner <erg@alum.mit.edu>
+Date: Thu Jan 30 08:45:06 2014 -0500
+
+ Remove change made in d19b672a3c06f0ae95b1da38b63b068f71eb266f until we can
+ remember why this change was made.
+
+diff --git a/lib/cgraph/scan.l b/lib/cgraph/scan.l
+index 0a31f0c..5bb30b7 100644
+--- a/lib/cgraph/scan.l
++++ b/lib/cgraph/scan.l
+@@ -199,6 +199,7 @@ ID ({NAME}|{NUMBER})
+ ["] BEGIN(qstring); beginstr();
+ <qstring>["] BEGIN(INITIAL); endstr(); return (T_qatom);
+ <qstring>[\\]["] addstr ("\"");
++<qstring>[\\][\\] addstr ("\\\\");
+ <qstring>[\\][\n] line_num++; /* ignore escaped newlines */
+ <qstring>([^"\\]*|[\\]) addstr(yytext);
+ [<] BEGIN(hstring); html_nest = 1; beginstr();