Bug 65518

Summary: tp_debug_client_get_messages_finish has incorrect transfer annotation
Product: Telepathy Reporter: Simon McVittie <smcv>
Component: tp-glibAssignee: Simon McVittie <smcv>
Status: RESOLVED FIXED QA Contact: Telepathy bugs list <telepathy-bugs>
Severity: normal    
Priority: medium Keywords: patch
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: tp_debug_client_get_messages_finish: fix annotation
Add a simple JavaScript debug-client which collects debug logs

Description Simon McVittie 2013-06-07 17:30:47 UTC
Created attachment 80489 [details] [review]
tp_debug_client_get_messages_finish: fix annotation

Returning a GPtrArray with (transfer full) means the caller is expected
to do the equivalent of:

    g_ptr_array_foreach (pa, (GFunc) g_free, NULL);
    g_ptr_array_unref (pa);

whereas we just want them to unref it. This crashed my g-i-based
debug-client.
Comment 1 Simon McVittie 2013-06-07 17:31:56 UTC
Created attachment 80490 [details] [review]
Add a simple JavaScript debug-client which collects  debug logs

---

Here's why I wanted that patch. Since empathy-debugger is crashing somewhere in Gtk/Cairo[1], it's useful to have a less Gtk-ish version.

[1] https://bugzilla.gnome.org/show_bug.cgi?id=696328
Comment 2 Simon McVittie 2013-06-07 17:32:57 UTC
If someone finishes Bug #48769 then this script would get really short, but until then, something > nothing.
Comment 3 Guillaume Desmottes 2013-06-10 08:00:55 UTC
Comment on attachment 80489 [details] [review]
tp_debug_client_get_messages_finish: fix annotation

Review of attachment 80489 [details] [review]:
-----------------------------------------------------------------

++
Comment 4 Guillaume Desmottes 2013-06-10 08:05:15 UTC
Comment on attachment 80490 [details] [review]
Add a simple JavaScript debug-client which collects  debug logs

Review of attachment 80490 [details] [review]:
-----------------------------------------------------------------

Didn't review this carefully, but if it works I'd say go for it.

But yeah, it would be good to finish bug #48769 at some point.
Comment 5 Guillaume Desmottes 2013-06-10 08:08:31 UTC
While you're on it, care to review https://bugzilla.gnome.org/show_bug.cgi?id=701914 ?
Comment 6 Simon McVittie 2013-06-10 14:03:59 UTC
In git for 0.20.3 and 0.21.1, thanks. Also, I reviewed your Empathy patch.

How about <https://bugs.freedesktop.org/show_bug.cgi?id=65517>?

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.