summaryrefslogtreecommitdiff
path: root/content/handlers/html/box_construct.c
diff options
context:
space:
mode:
authorMichael Drake <michael.drake@codethink.co.uk>2019-05-06 17:29:53 +0100
committerMichael Drake <michael.drake@codethink.co.uk>2019-05-06 17:29:53 +0100
commita43b83de0369228b935b693390186e5a8804340d (patch)
treef9a1dd310387f580e87489a64c88bafe9f5d3337 /content/handlers/html/box_construct.c
parent65b16f4c54eba748ee4c8b6580e6f08fc27534f8 (diff)
downloadnetsurf-a43b83de0369228b935b693390186e5a8804340d.tar.gz
netsurf-a43b83de0369228b935b693390186e5a8804340d.tar.bz2
HTML: Squash error-path leaks in select box construction.
Diffstat (limited to 'content/handlers/html/box_construct.c')
-rw-r--r--content/handlers/html/box_construct.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/content/handlers/html/box_construct.c b/content/handlers/html/box_construct.c
index eb3bba7c3..4d0cba748 100644
--- a/content/handlers/html/box_construct.c
+++ b/content/handlers/html/box_construct.c
@@ -2719,6 +2719,7 @@ bool box_select(BOX_SPECIAL_PARAMS)
c2) == false) {
dom_node_unref(c2);
dom_node_unref(c);
+ form_free_control(gadget);
return false;
}
} else {
@@ -2729,6 +2730,7 @@ bool box_select(BOX_SPECIAL_PARAMS)
if (err != DOM_NO_ERR) {
dom_node_unref(c2);
dom_node_unref(c);
+ form_free_control(gadget);
return false;
}