diff options
-rw-r--r-- | wombat/ChangeLog | 6 | ||||
-rw-r--r-- | wombat/wombat.c | 20 |
2 files changed, 26 insertions, 0 deletions
diff --git a/wombat/ChangeLog b/wombat/ChangeLog index a76545aa3a..b9cf6592a6 100644 --- a/wombat/ChangeLog +++ b/wombat/ChangeLog @@ -1,3 +1,9 @@ +2001-10-29 Chris Toshok <toshok@ximian.com> + + * wombat.c (dump_backends): new function, ifdef'ed DEBUG_BACKENDS. + (main): add SIGUSR2 handler for dump_backends, ifdef'ed + DEBUG_BACKENDS. + 2001-10-22 Ettore Perazzoli <ettore@ximian.com> * wombat.c (main): Register the public ConfigDatabase interface diff --git a/wombat/wombat.c b/wombat/wombat.c index f7fbc9227c..fba9b9e898 100644 --- a/wombat/wombat.c +++ b/wombat/wombat.c @@ -9,7 +9,14 @@ #include <config.h> #endif +/* define this if you need/want to be able to send USR2 to wombat and + get a list of the active backends */ +/*#define DEBUG_BACKENDS*/ + #include <stdlib.h> +#ifdef DEBUG_BACKENDS +#include <sys/signal.h> +#endif #include <glib.h> #include <libgnome/gnome-defs.h> #include <libgnome/gnome-i18n.h> @@ -220,6 +227,15 @@ init_bonobo (int *argc, char **argv) } } +#ifdef DEBUG_BACKENDS +static void +dump_backends (int signal) +{ + pas_book_factory_dump_active_backends (pas_book_factory); + cal_factory_dump_active_backends (cal_factory); +} +#endif + int main (int argc, char **argv) { @@ -230,6 +246,10 @@ main (int argc, char **argv) g_message ("Starting wombat"); +#ifdef DEBUG_BACKENDS + signal (SIGUSR2, dump_backends); +#endif + init_bonobo (&argc, argv); setup_vfs (argc, argv); |