[gjs] system: Fix leak in addressOf()
- From: Giovanni Campagna <gcampagna src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs] system: Fix leak in addressOf()
- Date: Wed, 13 Mar 2013 16:46:18 +0000 (UTC)
commit 9d9576edfc6e293cc70b7217148ed7dbea151dc8
Author: Pavel Vasin <rat4vier gmail com>
Date: Tue Mar 5 10:04:44 2013 +0400
system: Fix leak in addressOf()
https://bugzilla.gnome.org/show_bug.cgi?id=695186
modules/system.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/modules/system.c b/modules/system.c
index c650a8a..6b68b77 100644
--- a/modules/system.c
+++ b/modules/system.c
@@ -48,6 +48,8 @@ gjs_address_of(JSContext *context,
pointer_string = g_strdup_printf("%p", target_obj);
ret = gjs_string_from_utf8(context, pointer_string, -1, &retval);
+ g_free(pointer_string);
+
if (ret)
JS_SET_RVAL(context, vp, retval);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]