summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--telepathy-glib/simple-password-manager.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/telepathy-glib/simple-password-manager.c b/telepathy-glib/simple-password-manager.c
index cdb75b8d9..50d2ecee6 100644
--- a/telepathy-glib/simple-password-manager.c
+++ b/telepathy-glib/simple-password-manager.c
@@ -305,6 +305,12 @@ tp_simple_password_manager_channel_closed_cb (GObject *chan,
}
static void
+free_gstring (gpointer p)
+{
+ g_string_free (p, TRUE);
+}
+
+static void
tp_simple_password_manager_channel_finished_cb (
TpBasePasswordChannel *channel,
const GString *str,
@@ -325,7 +331,7 @@ tp_simple_password_manager_channel_finished_cb (
else
{
g_simple_async_result_set_op_res_gpointer (
- result, (gpointer) str, NULL);
+ result, g_boxed_copy (G_TYPE_GSTRING, str), free_gstring);
}
g_simple_async_result_complete (result);