Re: E and Solaris 2.6 bugs



Mark R. Bowyer wrote:

> >From: raster@redhat.com
> 
> >one process is forked... it handles the "screen" thats put up whilst
> >restarting.. thsi screen stays up to "cover up" nasty operations behind
> >the scenes.. it does have its own display connection etc. though. maybe
> >somehow the fd under solaris is retained between forks so the display
> >connection is still active.. and thus select on root window still
> >active... tho it seems on linux this doesnt happen. (Xlib sets the X fd
> >to "close on exec").
> 
> Could be.  I've seen 3 processes before, but that was before the forking for 
> multiple display code was fixed.  How could I check for still-open X fds?

I've checked on Solaris 7. It stays open. There are several ways to check
that. The simplest was to write a small program, like this:

#include <stdlib.h>
#include <X11/Xlib.h>

main()
{
   Display *d;

   d = XOpenDisplay(NULL);
   fork();
   sleep(500);
}

When you start it, you can check open file descriptors with lsof. If you
don't have it, `ls /proc/proc_ID_here/fd' will do. Both processes have
fd 4, which is a pipe.

-- 
 .-.   .-.    Life is a sexually transmitted disease.
(_  \ /  _)
     |        dave@srce.hr
     |        dave@fly.cc.fer.hr



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