|
From: Petr M. <mi...@ph...> - 2003-12-17 11:45:57
|
> Petr: you already added a good deal of #ifdef PIPE_IPCs around this
> in end of October 2003 (x11 reversions 1.82, 1.83), so it now looks like
> this:
>
> #ifdef USE_MOUSE
> /* EAM June 2003 - Flush the set font command through the pipe */
> /* to gnuplot_x11, then wait for it to return the resulting */
> /* font size information (v_char and h_char). */
> if (!default_font_size_known) {
> #ifdef PIPE_IPC
> IPC_LOCK = TRUE;
> #endif
> X11_set_default_font();
> FFLUSH();
> #ifdef PIPE_IPC
> if (ipc_back_fd >= 0)
> #endif
> X11_waitforinput();
> default_font_size_known = TRUE;
> #ifdef PIPE_IPC
> IPC_LOCK = FALSE;
> #endif
> }
> #else
> X11_set_default_font();
> #endif
>
> Petr: I guess you or Franz will have to single-step through this part
> and find out at exactly which part of it the garbage turns up.
Franz did it and there is his answer:
***
Delete
X11_waitforinput();
in x11.trm (line 1053 in 15/12/2003 sources)
and try again.
This works for me, but I don't know if it's the right fix.
***
Consequently, this piece of code:
#ifdef PIPE_IPC
if (ipc_back_fd >= 0)
#endif
X11_waitforinput();
should be:
#ifdef PIPE_IPC
if (ipc_back_fd >= 0)
X11_waitforinput();
#endif
and everything works OK in gnuplot versions up to yesterday.
The patch commited by Ethan works fine as well.
Thus, what should be the best version there?
---
Petr Mikulik
|