[PATCH test/xts] Fix segfault in XtCallbackReleaseCacheRefList test
Peter Harris
pharris at opentext.com
Wed Aug 1 08:01:20 PDT 2012
XtCallbackReleaseCacheRefList frees its parameter.
Signed-off-by: Peter Harris <pharris at opentext.com>
---
xts5/Xt11/XtCallbackReleaseCacheRefList.m | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/xts5/Xt11/XtCallbackReleaseCacheRefList.m b/xts5/Xt11/XtCallbackReleaseCacheRefList.m
index 7174fae..1b2cf04 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");
--
1.7.2.5
More information about the xorg-devel
mailing list