summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-11-12 09:19:23 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-11-12 15:12:24 -0800
commit34b1fb5d114b6c763c06dd9618c3d8ca11662e34 (patch)
tree339d430299698f0861b07f6850bf8542b34f4743
parentf5b9df0bac82a29f7a12837b176293f3a5b7452a (diff)
Issue #5: incompatible function pointer passed in _XawImRealize()
Import wrapper function with expected arguments from libXaw, where it appears to have been originally fixed in XFree86 3.9Nb by Paulo Cesar Pereira de Andrade. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--configure.ac2
-rw-r--r--src/Vendor.c10
-rw-r--r--src/XawIm.c9
3 files changed, 18 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index b96a4ad..7263fa5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -35,7 +35,7 @@ if test ! -f "$srcdir/src/laylex.c"; then
fi
# Checks for header files.
-PKG_CHECK_MODULES(X11, [x11 xt xmu xext])
+PKG_CHECK_MODULES(X11, [x11 xt xmu xext xproto >= 7.0.22])
AC_CHECK_HEADERS([wctype.h wchar.h widec.h])
AC_CHECK_FUNCS([iswspace])
AC_TYPE_INTPTR_T
diff --git a/src/Vendor.c b/src/Vendor.c
index 6b34b31..2b2b99f 100644
--- a/src/Vendor.c
+++ b/src/Vendor.c
@@ -109,6 +109,8 @@ static XtGeometryResult GeometryManager(Widget, XtWidgetGeometry *, XtWidgetGeom
static void XawVendorShellClassPartInit(WidgetClass);
void XawVendorShellExtResize(Widget);
#endif
+void XawVendorStructureNotifyHandler(Widget, XtPointer, XEvent*, Boolean*);
+
#if defined(__UNIXOS2__) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__)
/* to fix the EditRes problem because of wrong linker semantics */
@@ -576,6 +578,14 @@ XawVendorShellExtResize(Widget w)
}
}
}
+
+/*ARGSUSED*/
+void
+XawVendorStructureNotifyHandler(Widget w, XtPointer closure _X_UNUSED, XEvent *event _X_UNUSED,
+ Boolean *continue_to_dispatch _X_UNUSED)
+{
+ XawVendorShellExtResize(w);
+}
#endif
/*ARGSUSED*/
diff --git a/src/XawIm.c b/src/XawIm.c
index 9f666d2..67f941d 100644
--- a/src/XawIm.c
+++ b/src/XawIm.c
@@ -90,7 +90,12 @@ in this Software without prior written authorization from the X Consortium.
*
*****************************************************/
-extern void XawVendorShellExtResize(Widget);
+/*
+ * From Vendor.c
+ */
+void XawVendorShellExtResize(Widget);
+void XawVendorStructureNotifyHandler(Widget, XtPointer, XEvent*, Boolean*);
+
static XawIcTableList CurrentSharedIcTable(
XawVendorShellExtPart* /* ve */
@@ -1373,7 +1378,7 @@ _XawImRealize(
if ( !XtIsRealized( w ) || !XtIsVendorShell( w ) ) return;
if ((ve = GetExtPart( (VendorShellWidget) w ))) {
XtAddEventHandler( w, (EventMask)StructureNotifyMask, FALSE,
- XawVendorShellExtResize, (XtPointer)NULL );
+ XawVendorStructureNotifyHandler, (XtPointer)NULL );
AllCreateIC(ve);
}
}