octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #31641] fltk print crash on cygwin


From: marco atzeri
Subject: [Octave-bug-tracker] [bug #31641] fltk print crash on cygwin
Date: Tue, 13 Sep 2011 10:49:56 +0000
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:6.0.2) Gecko/20100101 Firefox/6.0.2

Follow-up Comment #9, bug #31641 (project octave):

the pclose is where the segfault arise, but
I suspect is not the root cause just a consequence.

Further tracing popen/open/close on the pipe handle/descriptor
I think the sequence is :

- popen in OpenGL_fltk::draw(), 
  creating pipe 5 and 6 (handle 0x20204F9C)
  (pipe 5 is closed as the communication is unidirectional)

- fdopen (6) in glps_renderer::draw 
  duplicating the handle (new handle 0x2020500C)

- a lot of writing to 6

- fclose (0x2020500C) in glps_renderer::draw 
  this is causing fclose to call : close(6)
-----------------------------------------------
Run till exit from #0  fclose (fp=0x2020500c)
    at ../../../../../src_new/newlib/libc/stdio/fclose.c:116

Breakpoint 6, close (fd=6)
    at /pub/cygwin/cvs/src_new/winsup/cygwin/syscalls.cc:1214
------------------------------------------------

- pclose(0x20204F9C) in OpenGL_fltk::draw()
  that SEGFAULT's as fd=6 is already closed

The close(6) seems an abnormal beahviour of fclose as 
there is another FILE handle still open.


What I don't know if there is a bug in fclose or 
if the behaviour is correct due to some settings.

 

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?31641>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]