posix signal handling

Brian J. Tarricone bjt23 at cornell.edu
Mon Dec 17 19:24:25 CET 2007


Hey guys,

This weekend I committed some new functionality to libxfce4util: 
integration of POSIX signal handling with the glib main loop.  I'm 
already using it in xfdesktop and it seems to work fine.  It's basically 
the same thing I changed xfce-mcs-manager to do a while ago, and I think 
Jasper might have copied that for the panel.  xfwm4 should probably use 
it as well; not sure if there are other of our apps that handle signals.

The header is here:
http://svn.xfce.org/svn/xfce/libxfce4util/trunk/libxfce4util/xfce-posix-signal-handler.h
Source is in the corresponding .c file, of course.

Please let me know your thoughts on the API and implementation.  One 
thing I decided I didn't want to do was make a GObject proxy that has 
signals, the main reason being that I may submit this for inclusion into 
glib (not gobject).

Also, it lacks a "xfce_posix_signal_handler_ignore_signal()" function. 
This is more due to laziness than anything else, since I think it's just 
as easy (if not easier) to call signal(SIGFOO, SIG_IGN); (though that 
breaks the abstraction).  Not sure if I should bother to add this.

Any comments/suggestions?

	-brian



More information about the Xfce4-dev mailing list