]> granicus.if.org Git - graphviz/commitdiff
Fix bug with uninitialized Agsym_t*. This causes problems when command-line -G, ...
authorEmden Gansner <erg@research.att.com>
Mon, 13 Aug 2012 20:14:47 +0000 (16:14 -0400)
committerEmden Gansner <erg@research.att.com>
Mon, 13 Aug 2012 20:14:47 +0000 (16:14 -0400)
are used.

lib/cgraph/grammar.y

index 0bde9e07f74868e97d75590611d2c1c50e196ade..3e3828a241e2d34dc56cd84557e1bb79970047e5 100644 (file)
@@ -330,6 +330,8 @@ static void attrstmt(int tkind, char *macroname)
        for (aptr = Attrlist.first; aptr; aptr = aptr->next) {
                if (!(aptr->u.asym->fixed) || (G->root != G))
                        sym = agattr(G,kind,aptr->u.asym->name,aptr->str);
+               else
+                       sym = aptr->u.asym;
                if (G->root == G)
                        sym->print = TRUE;
        }