]> granicus.if.org Git - graphviz/commitdiff
Fix precedence bug in gvdevice.c;
authorerg <devnull@localhost>
Tue, 4 Dec 2007 21:22:17 +0000 (21:22 +0000)
committererg <devnull@localhost>
Tue, 4 Dec 2007 21:22:17 +0000 (21:22 +0000)
move fflush to end_graph rather than end_page, because the dot and
xdot renderers don't call agwrite until end_graph. Right now the
fflush flushes nothing.

lib/gvc/gvdevice.c
lib/gvc/gvrender.c

index bdc0ce797e6d2e02f1c2570b044a94e0e4739355..613d54055fc491af769f8195421072d4cfcd1f8d 100644 (file)
@@ -209,7 +209,7 @@ void gvdevice_format(GVJ_t * job)
     if (job->output_file
       && ! job->external_context
       && job->output_lang != TK
-      && ! job->flags & GVDEVICE_COMPRESSED_FORMAT)
+      && ! (job->flags & GVDEVICE_COMPRESSED_FORMAT))
        fflush(job->output_file);
 }
 
index 02dcc082ae8791b7d9f1a1667f20b21d360d027d..e507b9d5ac20151fe080cdb2b35729ec411b4b82 100644 (file)
@@ -306,6 +306,7 @@ void gvrender_end_graph(GVJ_t * job)
            cg->end_graph();
     }
 #endif
+    gvdevice_format(job);
 }
 
 void gvrender_begin_page(GVJ_t * job)
@@ -345,7 +346,6 @@ void gvrender_end_page(GVJ_t * job)
            cg->end_page();
     }
 #endif
-    gvdevice_format(job);
 }
 
 void gvrender_begin_layer(GVJ_t * job)