summaryrefslogtreecommitdiff
path: root/xts5/Xt11
diff options
context:
space:
mode:
authorPeter Harris <pharris@opentext.com>2012-07-30 15:47:27 -0400
committerPeter Harris <pharris@opentext.com>2012-08-15 14:20:05 -0400
commitc3a401f84ce701e310efb9de6ab5c031451e01f3 (patch)
tree2c97ce03af8d1a377407e096da05572132169f50 /xts5/Xt11
parentdee821dc98f995a3f02ed65609f0793fb94c2248 (diff)
Fix segfault in XtCallbackReleaseCacheRefList test
XtCallbackReleaseCacheRefList frees its parameter. Reviewed-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Signed-off-by: Peter Harris <pharris@opentext.com>
Diffstat (limited to 'xts5/Xt11')
-rw-r--r--xts5/Xt11/XtCallbackReleaseCacheRefList.m4
1 files changed, 3 insertions, 1 deletions
diff --git a/xts5/Xt11/XtCallbackReleaseCacheRefList.m b/xts5/Xt11/XtCallbackReleaseCacheRefList.m
index 7174faef..1b2cf043 100644
--- a/xts5/Xt11/XtCallbackReleaseCacheRefList.m
+++ b/xts5/Xt11/XtCallbackReleaseCacheRefList.m
@@ -114,7 +114,7 @@ Display *display_good;
XrmValue from, from_val;
XrmValue to_in_out;
XrmValue to_return;
-XtCacheRef cache_ref_return[3], cache_ref;
+XtCacheRef *cache_ref_return, cache_ref;
Boolean status;
XtPointer client_data;
pid_t pid2;
@@ -122,6 +122,8 @@ unsigned char tchar;
FORK(pid2);
avs_xt_hier("Tcalbrcrl1", "XtCallbackReleaseCacheRefList");
+ tet_infoline("PREP: Allocate list of resources");
+ cache_ref_return = XtMalloc(3 * sizeof(*cache_ref_return));
tet_infoline("PREP: Create windows for widgets and map them");
XtRealizeWidget(topLevel);
tet_infoline("PREP: Register resource converter");