From a645bb2ead19f04a0824b2d3b76224261958ba18 Mon Sep 17 00:00:00 2001 From: Miciah Dashiel Butler Masters Date: Thu, 5 Jan 2006 23:41:18 +0000 Subject: [PATCH] Do return EVENT_NOT_PROCESSED from hierbox_ev_init and hierbox_ev_abort hierbox_ev_init and hierbox_ev_abort must return EVENT_NOT_PROCESSED so that the generic dialog code runs and initialises the widgets and stuff. This commit reverts commit f8310de64be50b165eb2080d4a0bccd25a8d346f to fix a segfault and also adds comments to explain the unintuitive return value. --- src/bfu/hierbox.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/bfu/hierbox.c b/src/bfu/hierbox.c index db8884c6..f57b709d 100644 --- a/src/bfu/hierbox.c +++ b/src/bfu/hierbox.c @@ -235,7 +235,9 @@ hierbox_ev_init(struct dialog_data *dlg_data) litem->visible = 1; } - return EVENT_PROCESSED; + /* Return this so that the generic dialog code will run and initialise + * the widgets and stuff. */ + return EVENT_NOT_PROCESSED; } static widget_handler_status_T @@ -259,7 +261,9 @@ hierbox_ev_abort(struct dialog_data *dlg_data) } } - return EVENT_PROCESSED; + /* Return this so that the generic dialog code will run and initialise + * the widgets and stuff. */ + return EVENT_NOT_PROCESSED; }