# HG changeset patch # User Daniel Atallah # Date 1181849526 0 # Node ID 81d42bfe31fa2fe8763bc898d903157aa1d63838 # Parent 36ebcb33e2ebb703e1fbae9080a0459a90079cff I think this will fix the problem that elb had where bonjour (and probably other accounts too) were signing on initially when -n was specified. diff -r 36ebcb33e2eb -r 81d42bfe31fa libpurple/idle.c --- a/libpurple/idle.c Thu Jun 14 18:20:53 2007 +0000 +++ b/libpurple/idle.c Thu Jun 14 19:32:06 2007 +0000 @@ -300,6 +300,14 @@ return &handle; } +static gboolean _do_purple_idle_touch_cb(gpointer data) +{ + purple_idle_touch(); + + return FALSE; +} + + void purple_idle_init() { @@ -319,7 +327,10 @@ purple_prefs_connect_callback(purple_idle_get_handle(), "/purple/away/idle_reporting", idle_reporting_cb, NULL); - purple_idle_touch(); + /* Initialize the idleness asynchronously so it doesn't check idleness, + * and potentially try to change the status before the UI is initialized */ + g_idle_add(_do_purple_idle_touch_cb, NULL); + } void