From 9acc68b10b087a8b19add634cdec7f66d6caf51f Mon Sep 17 00:00:00 2001 From: Fred Pierresteguy Date: Tue, 15 Feb 1994 13:54:14 +0000 Subject: *** empty log message *** --- lwlib/lwlib-Xlw.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'lwlib/lwlib-Xlw.c') diff --git a/lwlib/lwlib-Xlw.c b/lwlib/lwlib-Xlw.c index 893833efca3..d34a012ae3c 100644 --- a/lwlib/lwlib-Xlw.c +++ b/lwlib/lwlib-Xlw.c @@ -75,7 +75,15 @@ static Widget xlw_create_menubar (instance) widget_instance* instance; { - Widget widget = + Widget widget; + + widget_value *tem = (widget_value *) XtMalloc (sizeof (widget_value)); + + /* _XtCreate is freeing the object we passed, + so make a copy that we free later. */ + bcopy (instance->info->val, tem, sizeof (widget_value)); + + widget = XtVaCreateWidget (instance->info->name, xlwMenuWidgetClass, instance->parent, XtNmenu, instance->info->val, -- cgit v1.2.1