]> granicus.if.org Git - graphviz/commitdiff
Fix bug 788
authorellson <devnull@localhost>
Tue, 18 Oct 2005 21:10:00 +0000 (21:10 +0000)
committerellson <devnull@localhost>
Tue, 18 Oct 2005 21:10:00 +0000 (21:10 +0000)
lib/common/shapes.c

index ac9f535c5241f37154aeb883072ea739ce05a8d1..dbda841d022f04699a7e7fefa5b329e86c42125f 100644 (file)
@@ -1917,7 +1917,7 @@ static shape_desc *user_shape(char *name)
     UserShape = ALLOC(N_UserShape, UserShape, shape_desc *);
     p = UserShape[i] = NEW(shape_desc);
     *p = Shapes[0];
-    p->name = name;
+    p->name = strdup(name);
     p->usershape = TRUE;
     if (Lib == NULL && strcmp(name, "custom"))
        agerr(AGWARN, "using %s for unknown shape %s\n", Shapes[0].name,