From: Matthew Fernandez Date: Sat, 15 Oct 2022 17:59:52 +0000 (-0700) Subject: smyrna get_data_dir: fix unchecked allocation failure X-Git-Tag: 7.0.0~3^2~10 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=367445b6c13814865f7ba8fb086c06812cf38ef4;p=graphviz smyrna get_data_dir: fix unchecked allocation failure --- diff --git a/cmd/smyrna/viewport.c b/cmd/smyrna/viewport.c index 5b8d5e2c5..6bd078e02 100644 --- a/cmd/smyrna/viewport.c +++ b/cmd/smyrna/viewport.c @@ -246,7 +246,7 @@ static gboolean gl_main_expose(gpointer data) static void get_data_dir(void) { free(view->template_file); - view->template_file = strdup(smyrnaPath("template.dot")); + view->template_file = gv_strdup(smyrnaPath("template.dot")); } void init_viewport(ViewInfo * view)