diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2012-12-04 18:13:10 +0000 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2013-10-21 12:37:46 +0100 |
commit | 2b1b3c4f6c271a64f6767c2cbd9f5713d0bdedaf (patch) | |
tree | 5dcd7074356192201beada223d93b23cd5ca3f7e | |
parent | b78ab1e3f845ae075afe8880c96568506135506c (diff) | |
download | dbus-glib-2b1b3c4f6c271a64f6767c2cbd9f5713d0bdedaf.tar.gz |
Fix yet another leak, this one caused by poor documentation (#29195)
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41129
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
-rw-r--r-- | test/core/error-mapping.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/core/error-mapping.c b/test/core/error-mapping.c index 122b6de..d66985f 100644 --- a/test/core/error-mapping.c +++ b/test/core/error-mapping.c @@ -115,6 +115,13 @@ throw_error_cb (DBusGProxy *proxy, f->error_name = g_strdup (dbus_g_error_get_name (error)); else f->error_name = NULL; + + /* On error, this callback is expected to free it, which is pretty + * astonishing, but is how it's always been. In principle, the generated + * code ought to document this, or something. + * https://bugs.freedesktop.org/show_bug.cgi?id=29195 + */ + g_error_free (error); } static void |