mcabber/mcabber/hbuf.c
changeset 2032 f740c4128f76
parent 1970 10eead2ba1b7
child 2268 f5402d705f67
--- a/mcabber/mcabber/hbuf.c	Sat Oct 13 19:53:12 2012 +0200
+++ b/mcabber/mcabber/hbuf.c	Sun Oct 14 17:39:11 2012 +0200
@@ -525,7 +525,7 @@
 //  hbuf_remove_receipt(hbuf, xep184)
 // Remove the Receipt Flag for the message with the given xep184 id
 // Returns TRUE if it was found and removed, otherwise FALSE
-gboolean hbuf_remove_receipt(GList *hbuf, gpointer xep184)
+gboolean hbuf_remove_receipt(GList *hbuf, gconstpointer xep184)
 {
   hbuf_block *blk;
 
@@ -533,7 +533,8 @@
 
   for ( ; hbuf; hbuf = g_list_previous(hbuf)) {
     blk = (hbuf_block*)(hbuf->data);
-    if (blk->prefix.xep184 == xep184) {
+    if (!g_strcmp0(blk->prefix.xep184, xep184)) {
+      g_free(blk->prefix.xep184);
       blk->prefix.xep184 = NULL;
       blk->prefix.flags ^= HBB_PREFIX_RECEIPT;
       return TRUE;