summaryrefslogtreecommitdiff
path: root/src/Create.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/Create.c')
-rw-r--r--src/Create.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Create.c b/src/Create.c
index 8131f42..511aa39 100644
--- a/src/Create.c
+++ b/src/Create.c
@@ -352,7 +352,7 @@ xtCreate(String name,
double widget_cache[100];
Widget req_widget;
XtPointer req_constraints = NULL;
- Cardinal wsize, csize;
+ Cardinal wsize;
Widget widget;
XtCacheRef *cache_refs;
XtCreateHookDataRec call_data;
@@ -415,6 +415,7 @@ xtCreate(String name,
CallInitialize(XtClass(widget), req_widget, widget, args, num_args);
if (parent_constraint_class != NULL) {
double constraint_cache[20];
+ Cardinal csize;
csize = parent_constraint_class->constraint_class.constraint_size;
if (csize) {
@@ -432,7 +433,7 @@ xtCreate(String name,
}
}
XtStackFree((XtPointer) req_widget, widget_cache);
- if (post_proc != (XtWidgetProc) NULL) {
+ if (post_proc != (XtWidgetProc) NULL && (parent != NULL)) {
Widget hookobj;
(*post_proc) (widget);