From 309f3d26f31595a1b61366621cf1a609f72e673f Mon Sep 17 00:00:00 2001 From: Miciah Dashiel Butler Masters Date: Sat, 24 Dec 2005 18:07:55 +0000 Subject: [PATCH] In smjs_get_keymap_object, free the private data JS_SetPrivate fails, per fonseca's suggestion. --- src/scripting/smjs/keybinding.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/scripting/smjs/keybinding.c b/src/scripting/smjs/keybinding.c index 50bb87a7e..0dc5de559 100644 --- a/src/scripting/smjs/keybinding.c +++ b/src/scripting/smjs/keybinding.c @@ -163,6 +163,8 @@ smjs_get_keymap_object(enum keymap_id keymap_id) if (JS_FALSE != JS_SetPrivate(smjs_ctx, keymap_object, data)) return keymap_object; + mem_free(data); + return NULL; }