From 3609f6c90c17c7c211ce3f449c265d115110bc94 Mon Sep 17 00:00:00 2001 From: Witold Filipczyk Date: Mon, 22 Jul 2024 19:07:18 +0200 Subject: [PATCH] [quickjs] memleak in getAttributeNode --- src/ecmascript/quickjs/element.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ecmascript/quickjs/element.c b/src/ecmascript/quickjs/element.c index df0755b79..be6056703 100644 --- a/src/ecmascript/quickjs/element.c +++ b/src/ecmascript/quickjs/element.c @@ -2842,6 +2842,7 @@ js_element_getAttributeNode(JSContext *ctx, JSValueConst this_val, int argc, JSV return JS_NULL; } exc = dom_element_get_attribute_node(el, attr_name, &attr); + dom_string_unref(attr_name); if (exc != DOM_NO_ERR || !attr) { //dom_node_unref(el);