diff options
Diffstat (limited to 'extra/graphviz/yyerror1.patch')
-rw-r--r-- | extra/graphviz/yyerror1.patch | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/extra/graphviz/yyerror1.patch b/extra/graphviz/yyerror1.patch new file mode 100644 index 000000000..4f1faf4df --- /dev/null +++ b/extra/graphviz/yyerror1.patch @@ -0,0 +1,26 @@ +From d266bb2b4154d11c27252b56d86963aef4434750 Mon Sep 17 00:00:00 2001 +From: "Emden R. Gansner" <erg@alum.mit.edu> +Date: Tue, 7 Jan 2014 10:45:36 -0500 +Subject: [PATCH] Prevent possible buffer overflow in yyerror() + +--- + lib/cgraph/scan.l | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/lib/cgraph/scan.l b/lib/cgraph/scan.l +index 3efe1d5..212967c 100644 +--- a/lib/cgraph/scan.l ++++ b/lib/cgraph/scan.l +@@ -201,7 +201,8 @@ void yyerror(char *str) + agxbput (&xb, InputFile); + agxbput (&xb, ": "); + } +- sprintf(buf," %s in line %d near '", str,line_num); ++ agxbput (&xb, str); ++ sprintf(buf," in line %d near '", line_num); + agxbput (&xb, buf); + agxbput (&xb, yytext); + agxbput (&xb,"'\n"); +-- +1.8.5.1 + |