From: erg Date: Tue, 20 Mar 2007 21:00:53 +0000 (+0000) Subject: Fix bug affecting old codegens. Need to make sure Output_file is X-Git-Tag: LAST_LIBGRAPH~32^2~5615 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a7aa14aecabecd4302041db7ba4a929df8d6db43;p=graphviz Fix bug affecting old codegens. Need to make sure Output_file is initialized before calling begin_job. The removes an assignment of Output_file from mpgen which was used to solve the same problem. Here we are solving it for all of the codegens. --- diff --git a/lib/common/emit.c b/lib/common/emit.c index df4c177d8..d26924660 100644 --- a/lib/common/emit.c +++ b/lib/common/emit.c @@ -2709,11 +2709,11 @@ int gvRenderJobs (GVC_t * gvc, graph_t * g) job->output_file = file_select(job->output_filename); else job->output_file = stdout; - gvrender_begin_job(job); /* FIXME? - semantics are unclear */ - } #ifdef WITH_CODEGENS - Output_file = job->output_file; + Output_file = job->output_file; #endif + gvrender_begin_job(job); /* FIXME? - semantics are unclear */ + } if (! (job->flags & GVRENDER_X11_EVENTS)) { /* Show_boxes is not defined, if at all,