# HG changeset patch # User Sadrul Habib Chowdhury # Date 1215964298 0 # Node ID fae54e746bdef503ffa29e666ffb555ff531cb6c # Parent 0e54d1fea7e2b525d005479662b9f8f54711e0d6 Initialize the commands subsystem before the plugins. This is necessary because plugins can add commands, and if the commands subsystem isn't initialized by then, it throws a runtime error, causing a crash with G_DEBUG=fatal_warnings (and from make check too, it seems). Thanks to Richard for finding the bug. diff -r 0e54d1fea7e2 -r fae54e746bde libpurple/core.c --- a/libpurple/core.c Sun Jul 13 10:09:19 2008 +0000 +++ b/libpurple/core.c Sun Jul 13 15:51:38 2008 +0000 @@ -131,6 +131,7 @@ #endif purple_ciphers_init(); + purple_cmds_init(); /* Since plugins get probed so early we should probably initialize their * subsystem right away too. @@ -170,7 +171,6 @@ purple_xfers_init(); purple_idle_init(); purple_smileys_init(); - purple_cmds_init(); /* * Call this early on to try to auto-detect our IP address and @@ -199,7 +199,6 @@ purple_connections_disconnect_all(); /* Save .xml files, remove signals, etc. */ - purple_cmds_uninit(); purple_smileys_uninit(); purple_idle_uninit(); purple_ssl_uninit(); @@ -233,6 +232,7 @@ purple_dbus_uninit(); #endif + purple_cmds_uninit(); purple_util_uninit(); purple_signals_uninit();