potential conflicts with run-time functions.
Also, ifdef'ed out two assignments in gvFreeLayout that are meaningless
using cgraph, as the GD_drawing(g) is already gone.
gvputs
gvRender
gvRenderData
+gvFreeRenderData
gvRenderFilename
gvRenderJobs
gvToggle
return rc;
}
+/* gvFreeRenderData:
+ * Utility routine to free memory allocated in gvRenderData, as the application code may use
+ * a different runtime library.
+ */
+void gvFreeRenderData (char* data)
+{
+ free (data);
+}
void gvAddLibrary(GVC_t *gvc, gvplugin_library_t *lib)
{
/* Render layout in a specified format to a malloc'ed string */
extern int gvRenderData(GVC_t *gvc, graph_t *g, const char *format, char **result, unsigned int *length);
+/* Free memory allocated and pointed to by *result in gvRenderData */
+extern void gvFreeRenderData (char* data);
+
/* Render layout according to -T and -o options found by gvParseArgs */
extern int gvRenderJobs(GVC_t *gvc, graph_t *g);
if (GD_drawing(g)) {
graph_cleanup(g);
+#ifndef WITH_CGRAPH
GD_drawing(g) = NULL;
GD_drawing(g->root) = NULL;
+#endif
}
return 0;
}