summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEtan Reisner <deryni@pidgin.im>2008-02-26 01:33:35 +0000
committerEtan Reisner <deryni@pidgin.im>2008-02-26 01:33:35 +0000
commita6d89f773b90ca8e50c434a708fe9cbf734f106b (patch)
tree2f08ad8b04f6ecf5399f4c11dc354a73d72c2029
parent580374c31e016582523c753e6a4a90ed8fdc1dd0 (diff)
downloadpidgin-a6d89f773b90ca8e50c434a708fe9cbf734f106b.tar.gz
Register and unregister the PurpleConnectionErrorInfo pointers with dbus, I
noticed DBus was screaming about them in the debug log of an unrelated ticket.
-rw-r--r--libpurple/account.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libpurple/account.c b/libpurple/account.c
index a4acbf7067..15b8389dfe 100644
--- a/libpurple/account.c
+++ b/libpurple/account.c
@@ -751,6 +751,7 @@ parse_current_error(xmlnode *node, PurpleAccount *account)
description = g_strdup("");
current_error = g_new0(PurpleConnectionErrorInfo, 1);
+ PURPLE_DBUS_REGISTER_POINTER(current_error, PurpleConnectionErrorInfo);
current_error->type = type;
current_error->description = description;
@@ -1009,6 +1010,7 @@ purple_account_destroy(PurpleAccount *account)
purple_log_free(account->system_log);
priv = PURPLE_ACCOUNT_GET_PRIVATE(account);
+ PURPLE_DBUS_UNREGISTER_POINTER(priv->current_error);
g_free(priv->current_error);
g_free(priv);
@@ -2365,8 +2367,7 @@ signed_on_cb(PurpleConnection *gc,
}
static void
-set_current_error(PurpleAccount *account,
- PurpleConnectionErrorInfo *new_err)
+set_current_error(PurpleAccount *account, PurpleConnectionErrorInfo *new_err)
{
PurpleAccountPrivate *priv = PURPLE_ACCOUNT_GET_PRIVATE(account);
PurpleConnectionErrorInfo *old_err = priv->current_error;
@@ -2384,6 +2385,7 @@ set_current_error(PurpleAccount *account,
if(old_err)
g_free(old_err->description);
+ PURPLE_DBUS_UNREGISTER_POINTER(old_err);
g_free(old_err);
}
@@ -2395,6 +2397,7 @@ connection_error_cb(PurpleConnection *gc,
{
PurpleAccount *account = purple_connection_get_account(gc);
PurpleConnectionErrorInfo *err = g_new0(PurpleConnectionErrorInfo, 1);
+ PURPLE_DBUS_REGISTER_POINTER(err, PurpleConnectionErrorInfo);
err->type = type;
err->description = g_strdup(description);