diff --git a/graphviz-wrong_index.patch b/graphviz-wrong_index.patch new file mode 100644 index 0000000..91d8ffe --- /dev/null +++ b/graphviz-wrong_index.patch @@ -0,0 +1,19 @@ +The second argument to the typeName function should be the ID of +a type, not a value. As typeName does no checking on it's arguments +it'll form a negative index for accessing the type names array. + +Patch by Emden R. Gansner + +Index: lib/gvpr/compile.c +=================================================================== +--- lib/gvpr/compile.c.orig 2009-11-22 20:10:33.000000000 +0100 ++++ lib/gvpr/compile.c 2010-06-01 12:52:04.902610547 +0200 +@@ -1514,7 +1514,7 @@ setval(Expr_t * pgm, Exnode_t * x, Exid_ + state->tvt = (trav_type) iv; + else + error(1, "unexpected value %d assigned to %s : ignored", +- iv, typeName(pgm, V_travtype)); ++ iv, typeName(pgm, T_tvtyp)); + break; + case V_travroot: + np = INT2PTR(Agnode_t *, v.integer); diff --git a/graphviz.changes b/graphviz.changes index b6c9bb5..63326e4 100644 --- a/graphviz.changes +++ b/graphviz.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Jun 1 16:29:05 UTC 2010 - pth@suse.de + +- Fix array underflow in lib/gvpr/compile.c + (graphviz-wrong_index.patch). + ------------------------------------------------------------------- Mon May 17 12:22:51 UTC 2010 - coolo@novell.com diff --git a/graphviz.spec b/graphviz.spec index 2174368..f9179bb 100644 --- a/graphviz.spec +++ b/graphviz.spec @@ -36,6 +36,7 @@ Patch3: graphviz-neato_splines.patch Patch11: graphviz-2.20.2-interpreter_names.patch Patch13: graphviz-stddefs.patch Patch14: graphviz-gd_png_check_sig.patch +Patch15: graphviz-wrong_index.patch Url: http://www.graphviz.org/ License: IBM Public License .. Prefix: /usr @@ -92,6 +93,7 @@ Authors: %patch11 %patch13 %patch14 +%patch15 # Fix path in generated man pages sed -e 's$@LIB_DIR@$%{_libdir}$g' tclpkg/gv/gv_doc_langs.tcl >tclpkg/gv/gv_doc_langs.tcl.new && mv tclpkg/gv/gv_doc_langs.tcl.new tclpkg/gv/gv_doc_langs.tcl # remove broken macros