summaryrefslogtreecommitdiff
path: root/editors/nedit
diff options
context:
space:
mode:
authordholland <dholland@pkgsrc.org>2013-04-28 20:35:22 +0000
committerdholland <dholland@pkgsrc.org>2013-04-28 20:35:22 +0000
commitbf44db0dc4e5d094d666de2ee9eafd03490e914a (patch)
treec579274bc339605065387c409be914586b5763e3 /editors/nedit
parentc3790b6ed1e0b6c9a17c5416d7fe9c795993b4ba (diff)
downloadpkgsrc-bf44db0dc4e5d094d666de2ee9eafd03490e914a.tar.gz
LP64 fixes & pass -Wall. Sort PLIST. PKGREVISION -> 5.
May help with PR 47777.
Diffstat (limited to 'editors/nedit')
-rw-r--r--editors/nedit/Makefile4
-rw-r--r--editors/nedit/PLIST4
-rw-r--r--editors/nedit/distinfo21
-rw-r--r--editors/nedit/patches/patch-Xlt_SlideC.c26
-rw-r--r--editors/nedit/patches/patch-source_highlight.c15
-rw-r--r--editors/nedit/patches/patch-source_interpret.c109
-rw-r--r--editors/nedit/patches/patch-source_macro.c61
-rw-r--r--editors/nedit/patches/patch-source_menu.c24
-rw-r--r--editors/nedit/patches/patch-source_parse.y141
-rw-r--r--editors/nedit/patches/patch-source_preferences.c41
-rw-r--r--editors/nedit/patches/patch-source_regularExp.c15
-rw-r--r--editors/nedit/patches/patch-source_search.c15
-rw-r--r--editors/nedit/patches/patch-source_selection.c24
-rw-r--r--editors/nedit/patches/patch-source_shell.c21
-rw-r--r--editors/nedit/patches/patch-source_tags.c17
-rw-r--r--editors/nedit/patches/patch-source_text.c33
-rw-r--r--editors/nedit/patches/patch-source_textBuf.c46
-rw-r--r--editors/nedit/patches/patch-source_textDisp.c16
-rw-r--r--editors/nedit/patches/patch-source_textDrag.c17
-rw-r--r--editors/nedit/patches/patch-source_userCmds.c34
-rw-r--r--editors/nedit/patches/patch-source_window.c28
-rw-r--r--editors/nedit/patches/patch-util_prefFile.c18
22 files changed, 725 insertions, 5 deletions
diff --git a/editors/nedit/Makefile b/editors/nedit/Makefile
index a1372f18284..cdcb4bf382d 100644
--- a/editors/nedit/Makefile
+++ b/editors/nedit/Makefile
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.51 2012/10/03 11:43:38 asau Exp $
+# $NetBSD: Makefile,v 1.52 2013/04/28 20:35:22 dholland Exp $
DISTNAME= nedit-${VERS}-src
PKGNAME= nedit-${VERS}
-PKGREVISION= 4
+PKGREVISION= 5
CATEGORIES= editors
MASTER_SITES= ${MASTER_SITE_NEDIT:=v${VERS:S/./_/g}/} \
${MASTER_SITE_SOURCEFORGE:=nedit/}
diff --git a/editors/nedit/PLIST b/editors/nedit/PLIST
index 43468a64009..656b88060a9 100644
--- a/editors/nedit/PLIST
+++ b/editors/nedit/PLIST
@@ -1,8 +1,8 @@
-@comment $NetBSD: PLIST,v 1.4 2009/06/14 17:50:25 joerg Exp $
+@comment $NetBSD: PLIST,v 1.5 2013/04/28 20:35:22 dholland Exp $
bin/nc
bin/nedit
-man/man1/nedit.1
man/man1/nedit-nc.1
+man/man1/nedit.1
share/doc/nedit/NEdit.ad
share/doc/nedit/README
share/doc/nedit/ReleaseNotes
diff --git a/editors/nedit/distinfo b/editors/nedit/distinfo
index 63ebd78371d..9eaa97b053a 100644
--- a/editors/nedit/distinfo
+++ b/editors/nedit/distinfo
@@ -1,6 +1,25 @@
-$NetBSD: distinfo,v 1.12 2005/02/23 17:15:12 agc Exp $
+$NetBSD: distinfo,v 1.13 2013/04/28 20:35:22 dholland Exp $
SHA1 (nedit-5.5-src.tar.bz2) = 7d3c87a793a5047cf857af1ac82e39f3b33e8a87
RMD160 (nedit-5.5-src.tar.bz2) = 93fce64bdc5d8a9eff86ab76cec67d44d676d0eb
Size (nedit-5.5-src.tar.bz2) = 1124825 bytes
+SHA1 (patch-Xlt_SlideC.c) = aafca789053536a0d3ca0bc98ae301c60697e4c2
SHA1 (patch-aa) = 29cf7e55b23e437b0203e0dde09cc053d65f245c
+SHA1 (patch-source_highlight.c) = f6c8de27402e3e6d4fd73cb11e541c5c053835d9
+SHA1 (patch-source_interpret.c) = 85bd739969674bbe436b79362dec7ef70204888e
+SHA1 (patch-source_macro.c) = bb00f95dae17053f9a01bd2b18ed6f1139f65314
+SHA1 (patch-source_menu.c) = 529be222b97904b82721dc79ae8fa587378ccd48
+SHA1 (patch-source_parse.y) = 9a126e619ec53b76bcfc404055642cb9e47df9e3
+SHA1 (patch-source_preferences.c) = 9d2d111e5bd1a06086f89bdcd3c692d2f9d6ca44
+SHA1 (patch-source_regularExp.c) = d607b663a3853a6963d3dea7a32ba6c42af681eb
+SHA1 (patch-source_search.c) = b60f984d803d58618813f39a4b93e27f2b9325c8
+SHA1 (patch-source_selection.c) = 28d0fd4eaddbd1e36ef2eef12ad28fa5adc406ca
+SHA1 (patch-source_shell.c) = 8d8b0820d509553140f2e1d173287122ed6d7a96
+SHA1 (patch-source_tags.c) = ae8ebe7ab48a154d7538e417540eeac223cae624
+SHA1 (patch-source_text.c) = e88669188ed3512ee3945ab68bb392d0f3aa7708
+SHA1 (patch-source_textBuf.c) = 06fadd285929922fe42904d3d49e7eacf4e61e90
+SHA1 (patch-source_textDisp.c) = 84e3631eb7076c77704390ac6aee66b27d0422f3
+SHA1 (patch-source_textDrag.c) = 8b66f1bb80bbc2b3cf3751ff7c601ded34b54646
+SHA1 (patch-source_userCmds.c) = 22c6468cffd2cd0d10af03452a2c14d63e893cbe
+SHA1 (patch-source_window.c) = 72fda2bf7cc178ec57f38d25915dab8a8765874d
+SHA1 (patch-util_prefFile.c) = 4accc0a25c7744076a7f8ee72c0a04328f0db915
diff --git a/editors/nedit/patches/patch-Xlt_SlideC.c b/editors/nedit/patches/patch-Xlt_SlideC.c
new file mode 100644
index 00000000000..149a3c929d4
--- /dev/null
+++ b/editors/nedit/patches/patch-Xlt_SlideC.c
@@ -0,0 +1,26 @@
+$NetBSD: patch-Xlt_SlideC.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Don't use NULL as an integer constant.
+
+--- Xlt/SlideC.c~ 2003-12-25 06:55:07.000000000 +0000
++++ Xlt/SlideC.c
+@@ -116,14 +116,14 @@ XltSlideContextClassRec xltSlideContextC
+ /* notify that initialize called XtArgsProc */ NULL,
+ /* NULL XtProc */ NULL,
+ /* NULL XtPointer */ NULL,
+-/* NULL Cardinal */ (Cardinal)NULL,
++/* NULL Cardinal */ (Cardinal)0,
+ /* resources for subclass fields XtResourceList */ resources,
+ /* number of entries in resources Cardinal */ XtNumber(resources),
+ /* resource class quarkified XrmClass */ NULLQUARK,
+-/* NULL Boolean */ (Boolean)NULL,
+-/* NULL XtEnum */ (XtEnum)NULL,
+-/* NULL Boolean */ (Boolean)NULL,
+-/* NULL Boolean */ (Boolean)NULL,
++/* NULL Boolean */ (Boolean)0,
++/* NULL XtEnum */ (XtEnum)0,
++/* NULL Boolean */ (Boolean)0,
++/* NULL Boolean */ (Boolean)0,
+ /* free data for subclass pointers XtWidgetProc */ destroy,
+ /* NULL XtProc */ NULL,
+ /* NULL XtProc */ NULL,
diff --git a/editors/nedit/patches/patch-source_highlight.c b/editors/nedit/patches/patch-source_highlight.c
new file mode 100644
index 00000000000..a1b2416f7bb
--- /dev/null
+++ b/editors/nedit/patches/patch-source_highlight.c
@@ -0,0 +1,15 @@
+$NetBSD: patch-source_highlight.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+
+--- source/highlight.c~ 2004-08-01 10:06:10.000000000 +0000
++++ source/highlight.c
+@@ -510,7 +510,7 @@ void* GetHighlightInfo(WindowInfo *windo
+ if (!pattern) {
+ return NULL;
+ }
+- return (void*)pattern->userStyleIndex;
++ return (void*)(intptr_t)pattern->userStyleIndex;
+ }
+
+ /*
diff --git a/editors/nedit/patches/patch-source_interpret.c b/editors/nedit/patches/patch-source_interpret.c
new file mode 100644
index 00000000000..6f062481d0a
--- /dev/null
+++ b/editors/nedit/patches/patch-source_interpret.c
@@ -0,0 +1,109 @@
+$NetBSD: patch-source_interpret.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+(This code should be rewritten to use a union, but I'm leaving that
+for upstream.)
+
+--- source/interpret.c~ 2004-07-21 11:32:05.000000000 +0000
++++ source/interpret.c
+@@ -1254,14 +1254,14 @@ static int pushArraySymVal(void)
+ {
+ Symbol *sym;
+ DataValue *dataPtr;
+- int initEmpty;
++ intptr_t initEmpty;
+
+ DISASM_RT(PC-1, 3);
+ STACKDUMP(0, 3);
+
+ sym = (Symbol *)*PC;
+ PC++;
+- initEmpty = (int)*PC;
++ initEmpty = (intptr_t)*PC;
+ PC++;
+
+ if (sym->type == LOCAL_SYM) {
+@@ -1872,7 +1872,7 @@ static int callSubroutine(void)
+ char *errMsg;
+
+ sym = (Symbol *)*PC++;
+- nArgs = (int)*PC++;
++ nArgs = (intptr_t)*PC++;
+
+ DISASM_RT(PC-3, 3);
+ STACKDUMP(nArgs, 3);
+@@ -2064,7 +2064,7 @@ static int branch(void)
+ DISASM_RT(PC-1, 2);
+ STACKDUMP(0, 3);
+
+- PC += (int)*PC;
++ PC += (intptr_t)*PC;
+ return STAT_OK;
+ }
+
+@@ -2085,7 +2085,7 @@ static int branchTrue(void)
+ STACKDUMP(1, 3);
+
+ POP_INT(value)
+- addr = PC + (int)*PC;
++ addr = PC + (intptr_t)*PC;
+ PC++;
+
+ if (value)
+@@ -2101,7 +2101,7 @@ static int branchFalse(void)
+ STACKDUMP(1, 3);
+
+ POP_INT(value)
+- addr = PC + (int)*PC;
++ addr = PC + (intptr_t)*PC;
+ PC++;
+
+ if (!value)
+@@ -2420,7 +2420,7 @@ static int arrayRef(void)
+ char *keyString = NULL;
+ int nDim;
+
+- nDim = (int)*PC;
++ nDim = (intptr_t)*PC;
+ PC++;
+
+ DISASM_RT(PC-2, 2);
+@@ -2471,7 +2471,7 @@ static int arrayAssign(void)
+ int errNum;
+ int nDim;
+
+- nDim = (int)*PC;
++ nDim = (intptr_t)*PC;
+ PC++;
+
+ DISASM_RT(PC-2, 1);
+@@ -2524,9 +2524,9 @@ static int arrayRefAndAssignSetup(void)
+ char *keyString = NULL;
+ int binaryOp, nDim;
+
+- binaryOp = (int)*PC;
++ binaryOp = (intptr_t)*PC;
+ PC++;
+- nDim = (int)*PC;
++ nDim = (intptr_t)*PC;
+ PC++;
+
+ DISASM_RT(PC-3, 3);
+@@ -2642,7 +2642,7 @@ static int arrayIter(void)
+ PC++;
+ iterator = (Symbol *)*PC;
+ PC++;
+- branchAddr = PC + (int)*PC;
++ branchAddr = PC + (intptr_t)*PC;
+ PC++;
+
+ if (item->type == LOCAL_SYM) {
+@@ -2739,7 +2739,7 @@ static int deleteArrayElement(void)
+ char *keyString = NULL;
+ int nDim;
+
+- nDim = (int)*PC;
++ nDim = (intptr_t)*PC;
+ PC++;
+
+ DISASM_RT(PC-2, 2);
diff --git a/editors/nedit/patches/patch-source_macro.c b/editors/nedit/patches/patch-source_macro.c
new file mode 100644
index 00000000000..fe6bc9a757a
--- /dev/null
+++ b/editors/nedit/patches/patch-source_macro.c
@@ -0,0 +1,61 @@
+$NetBSD: patch-source_macro.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call XtVaCreateManagedWidget and XtVaGetValues correctly.
+Silence gcc warnings about unsafe pointer casts.
+
+--- source/macro.c~ 2004-08-01 10:06:10.000000000 +0000
++++ source/macro.c
+@@ -2830,7 +2830,7 @@ static int dialogMS(WindowInfo *window,
+ for (i=1; i<nBtns; i++) {
+ btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
+ XmNlabelString, s1=XmStringCreateSimple(btnLabels[i]),
+- XmNuserData, (XtPointer)(i+1), NULL);
++ XmNuserData, (XtPointer)(intptr_t)(i+1), NULL);
+ XtAddCallback(btn, XmNactivateCallback, dialogBtnCB, window);
+ XmStringFree(s1);
+ }
+@@ -2871,7 +2871,7 @@ static void dialogBtnCB(Widget w, XtPoin
+ return; /* shouldn't happen */
+ if (XtClass(w) == xmPushButtonWidgetClass) {
+ XtVaGetValues(w, XmNuserData, &userData, NULL);
+- retVal.val.n = (int)userData;
++ retVal.val.n = (intptr_t)userData;
+ } else
+ retVal.val.n = 1;
+ retVal.tag = INT_TAG;
+@@ -3003,7 +3003,7 @@ static int stringDialogMS(WindowInfo *wi
+ for (i=1; i<nBtns; i++) {
+ btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
+ XmNlabelString, s1=XmStringCreateSimple(btnLabels[i]),
+- XmNuserData, (XtPointer)(i+1), NULL);
++ XmNuserData, (XtPointer)(intptr_t)(i+1), NULL);
+ XtAddCallback(btn, XmNactivateCallback, stringDialogBtnCB, window);
+ XmStringFree(s1);
+ }
+@@ -3057,7 +3057,7 @@ static void stringDialogBtnCB(Widget w,
+ returned in w. */
+ if (XtClass(w) == xmPushButtonWidgetClass) {
+ XtVaGetValues(w, XmNuserData, &userData, NULL);
+- btnNum = (int)userData;
++ btnNum = (intptr_t)userData;
+ } else
+ btnNum = 1;
+
+@@ -3456,7 +3456,7 @@ static int listDialogMS(WindowInfo *wind
+ for (i=1; i<nBtns; i++) {
+ btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
+ XmNlabelString, s1=XmStringCreateSimple(btnLabels[i]),
+- XmNuserData, (XtPointer)(i+1), NULL);
++ XmNuserData, (XtPointer)(intptr_t)(i+1), NULL);
+ XtAddCallback(btn, XmNactivateCallback, listDialogBtnCB, window);
+ XmStringFree(s1);
+ }
+@@ -3536,7 +3536,7 @@ static void listDialogBtnCB(Widget w, Xt
+ returned in w. */
+ if (XtClass(w) == xmPushButtonWidgetClass) {
+ XtVaGetValues(w, XmNuserData, &userData, NULL);
+- btnNum = (int)userData;
++ btnNum = (intptr_t)userData;
+ } else
+ btnNum = 1;
+
diff --git a/editors/nedit/patches/patch-source_menu.c b/editors/nedit/patches/patch-source_menu.c
new file mode 100644
index 00000000000..13444ba1a42
--- /dev/null
+++ b/editors/nedit/patches/patch-source_menu.c
@@ -0,0 +1,24 @@
+$NetBSD: patch-source_menu.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call XtVaGetValues correctly.
+
+--- source/menu.c~ 2004-09-15 22:50:57.000000000 +0000
++++ source/menu.c
+@@ -1242,7 +1242,7 @@ static Widget makeHelpMenuItem(
+ Widget menuItem =
+ createMenuItem( parent, name, label, mnemonic, callback, cbArg, mode );
+
+- XtVaSetValues( menuItem, XmNuserData, topic, 0 );
++ XtVaSetValues( menuItem, XmNuserData, topic, (char *)NULL);
+ return menuItem;
+ }
+
+@@ -1254,7 +1254,7 @@ static void helpCB( Widget menuItem, XtP
+
+ HidePointerOnKeyedEvent(WidgetToWindow(MENU_WIDGET(menuItem))->lastFocus,
+ ((XmAnyCallbackStruct *)callData)->event);
+- XtVaGetValues( menuItem, XmNuserData, &topic, 0 );
++ XtVaGetValues( menuItem, XmNuserData, &topic, (char *)NULL);
+
+ Help(topic);
+ }
diff --git a/editors/nedit/patches/patch-source_parse.y b/editors/nedit/patches/patch-source_parse.y
new file mode 100644
index 00000000000..fc950ca15fe
--- /dev/null
+++ b/editors/nedit/patches/patch-source_parse.y
@@ -0,0 +1,141 @@
+$NetBSD: patch-source_parse.y,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+
+--- source/parse.y~ 2003-12-19 23:23:31.000000000 +0000
++++ source/parse.y
+@@ -178,69 +178,69 @@ simpstmt: SYMBOL '=' expr {
+ ADD_OP(OP_BIT_OR); ADD_OP(OP_ASSIGN); ADD_SYM($1);
+ }
+ | DELETE arraylv '[' arglist ']' {
+- ADD_OP(OP_ARRAY_DELETE); ADD_IMMED((void *)$4);
++ ADD_OP(OP_ARRAY_DELETE); ADD_IMMED((void *)(intptr_t)$4);
+ }
+ | initarraylv '[' arglist ']' '=' expr {
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' ADDEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_ADD);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' SUBEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_SUB);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' MULEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_MUL);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' DIVEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_DIV);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' MODEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_MOD);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' ANDEQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_BIT_AND);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' OREQ expr {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)1); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)1); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_BIT_OR);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' INCR {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)0); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)0); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_INCR);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | initarraylv '[' arglist ']' DECR {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)0); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)0); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_DECR);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | INCR initarraylv '[' arglist ']' {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)0); ADD_IMMED((void *)$4);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)0); ADD_IMMED((void *)(intptr_t)$4);
+ ADD_OP(OP_INCR);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$4);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$4);
+ }
+ | DECR initarraylv '[' arglist ']' {
+- ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)0); ADD_IMMED((void *)$4);
++ ADD_OP(OP_ARRAY_REF_ASSIGN_SETUP); ADD_IMMED((void *)(intptr_t)0); ADD_IMMED((void *)(intptr_t)$4);
+ ADD_OP(OP_DECR);
+- ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)$4);
++ ADD_OP(OP_ARRAY_ASSIGN); ADD_IMMED((void *)(intptr_t)$4);
+ }
+ | SYMBOL '(' arglist ')' {
+ ADD_OP(OP_SUBR_CALL);
+- ADD_SYM(PromoteToGlobal($1)); ADD_IMMED((void *)$3);
++ ADD_SYM(PromoteToGlobal($1)); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | INCR SYMBOL {
+ ADD_OP(OP_PUSH_SYM); ADD_SYM($2); ADD_OP(OP_INCR);
+@@ -289,17 +289,17 @@ expr: numexpr %prec CONCAT
+ }
+ ;
+ initarraylv: SYMBOL {
+- ADD_OP(OP_PUSH_ARRAY_SYM); ADD_SYM($1); ADD_IMMED((void *)1);
++ ADD_OP(OP_PUSH_ARRAY_SYM); ADD_SYM($1); ADD_IMMED((void *)(intptr_t)1);
+ }
+ | initarraylv '[' arglist ']' {
+- ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ ;
+ arraylv: SYMBOL {
+- ADD_OP(OP_PUSH_ARRAY_SYM); ADD_SYM($1); ADD_IMMED((void *)0);
++ ADD_OP(OP_PUSH_ARRAY_SYM); ADD_SYM($1); ADD_IMMED((void *)(intptr_t)0);
+ }
+ | arraylv '[' arglist ']' {
+- ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ ;
+ arrayexpr: numexpr {
+@@ -317,7 +317,7 @@ numexpr: NUMBER {
+ }
+ | SYMBOL '(' arglist ')' {
+ ADD_OP(OP_SUBR_CALL);
+- ADD_SYM(PromoteToGlobal($1)); ADD_IMMED((void *)$3);
++ ADD_SYM(PromoteToGlobal($1)); ADD_IMMED((void *)(intptr_t)$3);
+ ADD_OP(OP_FETCH_RET_VAL);
+ }
+ | '(' expr ')'
+@@ -331,7 +331,7 @@ numexpr: NUMBER {
+ ADD_OP(OP_PUSH_ARG_ARRAY);
+ }
+ | numexpr '[' arglist ']' {
+- ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)$3);
++ ADD_OP(OP_ARRAY_REF); ADD_IMMED((void *)(intptr_t)$3);
+ }
+ | numexpr '+' numexpr {
+ ADD_OP(OP_ADD);
diff --git a/editors/nedit/patches/patch-source_preferences.c b/editors/nedit/patches/patch-source_preferences.c
new file mode 100644
index 00000000000..c85d00927e4
--- /dev/null
+++ b/editors/nedit/patches/patch-source_preferences.c
@@ -0,0 +1,41 @@
+$NetBSD: patch-source_preferences.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+
+--- source/preferences.c~ 2004-08-20 19:33:20.000000000 +0000
++++ source/preferences.c
+@@ -2161,7 +2161,7 @@ void SetLanguageMode(WindowInfo *window,
+ XtVaGetValues(menu, XmNchildren, &items, XmNnumChildren, &nItems, NULL);
+ for (n=0; n<(int)nItems; n++) {
+ XtVaGetValues(items[n], XmNuserData, &userData, NULL);
+- XmToggleButtonSetState(items[n], (int)userData == mode, False);
++ XmToggleButtonSetState(items[n], (intptr_t)userData == mode, False);
+ }
+ }
+ }
+@@ -4946,7 +4946,7 @@ static void updateLanguageModeSubmenu(Wi
+ xmToggleButtonGadgetClass, menu,
+ XmNlabelString, s1=XmStringCreateSimple(LanguageModes[i]->name),
+ XmNmarginHeight, 0,
+- XmNuserData, (void *)i,
++ XmNuserData, (void *)(intptr_t)i,
+ XmNset, window->languageMode==i, NULL);
+ XmStringFree(s1);
+ XtAddCallback(btn, XmNvalueChangedCallback, setLangModeCB, window);
+@@ -4967,14 +4967,14 @@ static void setLangModeCB(Widget w, XtPo
+ XtVaGetValues(w, XmNuserData, &mode, NULL);
+
+ /* If the mode didn't change, do nothing */
+- if (window->languageMode == (int)mode)
++ if (window->languageMode == (intptr_t)mode)
+ return;
+
+ /* redo syntax highlighting word delimiters, etc. */
+ /*
+ reapplyLanguageMode(window, (int)mode, False);
+ */
+- params[0] = (((int)mode) == PLAIN_LANGUAGE_MODE) ? "" : LanguageModes[(int)mode]->name;
++ params[0] = (((intptr_t)mode) == PLAIN_LANGUAGE_MODE) ? "" : LanguageModes[(intptr_t)mode]->name;
+ XtCallActionProc(window->textArea, "set_language_mode", NULL, params, 1);
+ }
+
diff --git a/editors/nedit/patches/patch-source_regularExp.c b/editors/nedit/patches/patch-source_regularExp.c
new file mode 100644
index 00000000000..bcd858642f2
--- /dev/null
+++ b/editors/nedit/patches/patch-source_regularExp.c
@@ -0,0 +1,15 @@
+$NetBSD: patch-source_regularExp.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Don't use NULL as an integer constant.
+
+--- source/regularExp.c~ 2004-08-20 16:37:30.000000000 +0000
++++ source/regularExp.c
+@@ -4092,7 +4092,7 @@ static unsigned char * makeDelimiterTabl
+ table [*c] = 1;
+ }
+
+- table [(int) NULL] = 1; /* These */
++ table [(int) '\0'] = 1; /* These */
+ table [(int) '\t'] = 1; /* characters */
+ table [(int) '\n'] = 1; /* are always */
+ table [(int) ' ' ] = 1; /* delimiters. */
diff --git a/editors/nedit/patches/patch-source_search.c b/editors/nedit/patches/patch-source_search.c
new file mode 100644
index 00000000000..dc916aaa37c
--- /dev/null
+++ b/editors/nedit/patches/patch-source_search.c
@@ -0,0 +1,15 @@
+$NetBSD: patch-source_search.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call XtVaGetValues correctly.
+
+--- source/search.c~ 2004-08-01 10:06:11.000000000 +0000
++++ source/search.c
+@@ -1042,7 +1042,7 @@ void CreateReplaceDlog(Widget parent, Wi
+ XtAddCallback(replaceBtn, XmNactivateCallback, (XtCallbackProc)replaceCB, window);
+ XmStringFree(st1);
+ XtManageChild(replaceBtn);
+- XtVaGetValues(replaceBtn, XmNshadowThickness, &shadowThickness, 0);
++ XtVaGetValues(replaceBtn, XmNshadowThickness, &shadowThickness, (char *)NULL);
+ defaultBtnOffset = shadowThickness + 4;
+
+ argcnt = 0;
diff --git a/editors/nedit/patches/patch-source_selection.c b/editors/nedit/patches/patch-source_selection.c
new file mode 100644
index 00000000000..3201d19885c
--- /dev/null
+++ b/editors/nedit/patches/patch-source_selection.c
@@ -0,0 +1,24 @@
+$NetBSD: patch-source_selection.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call <ctype.h> functions correctly.
+
+--- source/selection.c~ 2004-08-01 10:06:11.000000000 +0000
++++ source/selection.c
+@@ -563,7 +563,7 @@ void AddMark(WindowInfo *window, Widget
+
+ /* look for a matching mark to re-use, or advance
+ nMarks to create a new one */
+- label = toupper(label);
++ label = toupper((unsigned char)label);
+ for (index=0; index<window->nMarks; index++) {
+ if (window->markTable[index].label == label)
+ break;
+@@ -588,7 +588,7 @@ void GotoMark(WindowInfo *window, Widget
+ selection *sel, *oldSel;
+
+ /* look up the mark in the mark table */
+- label = toupper(label);
++ label = toupper((unsigned char)label);
+ for (index=0; index<window->nMarks; index++) {
+ if (window->markTable[index].label == label)
+ break;
diff --git a/editors/nedit/patches/patch-source_shell.c b/editors/nedit/patches/patch-source_shell.c
new file mode 100644
index 00000000000..94256314186
--- /dev/null
+++ b/editors/nedit/patches/patch-source_shell.c
@@ -0,0 +1,21 @@
+$NetBSD: patch-source_shell.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Avoid nasal demons if fork fails.
+
+--- source/shell.c~ 2004-09-02 08:49:56.000000000 +0000
++++ source/shell.c
+@@ -505,6 +505,14 @@ static void issueCommand(WindowInfo *win
+ /* fork the subprocess and issue the command */
+ childPid = forkCommand(window->shell, command, window->path, &stdinFD,
+ &stdoutFD, (flags & ERROR_DIALOGS) ? &stderrFD : NULL);
++
++ if (childPid == -1) {
++ /*
++ * XXX: there does not appear to be any way to handle this error;
++ * but at least let's avoid nasal demons.
++ */
++ stdinFD = stdoutFD = stderrFD = -1;
++ }
+
+ /* set the pipes connected to the process for non-blocking i/o */
+ if (fcntl(stdinFD, F_SETFL, O_NONBLOCK) < 0)
diff --git a/editors/nedit/patches/patch-source_tags.c b/editors/nedit/patches/patch-source_tags.c
new file mode 100644
index 00000000000..7308ec4bdc0
--- /dev/null
+++ b/editors/nedit/patches/patch-source_tags.c
@@ -0,0 +1,17 @@
+$NetBSD: patch-source_tags.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc 4.5 warnings about uninitialized variables.
+
+--- source/tags.c~ 2004-08-01 10:06:11.000000000 +0000
++++ source/tags.c
+@@ -1945,6 +1945,10 @@ static int loadTipsFile(const char *tips
+ int nTipsAdded=0, langMode = PLAIN_LANGUAGE_MODE, oldLangMode;
+ int currLine=0, code, blkLine;
+ tf_alias *aliases=NULL, *tmp_alias;
++
++ /* silence gcc 4.5 warnings */
++ body = NULL;
++ blkLine = 0;
+
+ if(recLevel > MAX_TAG_INCLUDE_RECURSION_LEVEL) {
+ fprintf(stderr, "nedit: Warning: Reached recursion limit before loading calltips file:\n\t%s\n", tipsFile);
diff --git a/editors/nedit/patches/patch-source_text.c b/editors/nedit/patches/patch-source_text.c
new file mode 100644
index 00000000000..3493dbaa986
--- /dev/null
+++ b/editors/nedit/patches/patch-source_text.c
@@ -0,0 +1,33 @@
+$NetBSD: patch-source_text.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call XtVaGetValues correctly.
+
+--- source/text.c~ 2004-07-28 18:02:03.000000000 +0000
++++ source/text.c
+@@ -3126,7 +3126,7 @@ static void pageRightAP(Widget w, XEvent
+ cancelDrag(w);
+ if (hasKey("scrollbar", args, nArgs)) {
+ XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
+- XmNsliderSize, &sliderSize, 0);
++ XmNsliderSize, &sliderSize, (char*)NULL);
+ horizOffset = min(textD->horizOffset + textD->width, sliderMax - sliderSize);
+ if (textD->horizOffset == horizOffset) {
+ ringIfNecessary(silent, w);
+@@ -3218,7 +3218,7 @@ static void scrollLeftAP(Widget w, XEven
+ if (*nArgs == 0 || sscanf(args[0], "%d", &nPixels) != 1)
+ return;
+ XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
+- XmNsliderSize, &sliderSize, 0);
++ XmNsliderSize, &sliderSize, (char *)NULL);
+ horizOffset = min(max(0, textD->horizOffset - nPixels), sliderMax - sliderSize);
+ if (textD->horizOffset != horizOffset) {
+ TextDSetScroll(textD, textD->topLineNum, horizOffset);
+@@ -3235,7 +3235,7 @@ static void scrollRightAP(Widget w, XEve
+ if (*nArgs == 0 || sscanf(args[0], "%d", &nPixels) != 1)
+ return;
+ XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
+- XmNsliderSize, &sliderSize, 0);
++ XmNsliderSize, &sliderSize, (char *)NULL);
+ horizOffset = min(max(0, textD->horizOffset + nPixels), sliderMax - sliderSize);
+ if (textD->horizOffset != horizOffset) {
+ TextDSetScroll(textD, textD->topLineNum, horizOffset);
diff --git a/editors/nedit/patches/patch-source_textBuf.c b/editors/nedit/patches/patch-source_textBuf.c
new file mode 100644
index 00000000000..fc875339953
--- /dev/null
+++ b/editors/nedit/patches/patch-source_textBuf.c
@@ -0,0 +1,46 @@
+$NetBSD: patch-source_textBuf.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc 4.5 warnings about uninitialized variables.
+
+--- source/textBuf.c~ 2004-07-21 11:32:05.000000000 +0000
++++ source/textBuf.c
+@@ -1592,6 +1592,9 @@ static void deleteRect(textBuffer *buf,
+ {
+ int nLines, lineStart, lineEnd, len, endOffset;
+ char *outStr, *outPtr, *line, *text, *expText;
++
++ /* this may be needed if the region is empty */
++ endOffset = 0;
+
+ /* allocate a buffer for the replacement string large enough to hold
+ possibly expanded tabs as well as an additional MAX_EXP_CHAR_LEN * 2
+@@ -1998,6 +2001,9 @@ static char *getSelectionText(textBuffer
+ {
+ int start, end, isRect, rectStart, rectEnd;
+ char *text;
++
++ /* silence bogus uninitialized variable warning from gcc 4.5 */
++ rectStart = rectEnd = 0;
+
+ /* If there's no selection, return an allocated empty string */
+ if (!getSelectionPos(sel, &start, &end, &isRect, &rectStart, &rectEnd)) {
+@@ -2018,6 +2024,9 @@ static void removeSelected(textBuffer *b
+ int start, end;
+ int isRect, rectStart, rectEnd;
+
++ /* silence bogus uninitialized variable warning from gcc 4.5 */
++ rectStart = rectEnd = 0;
++
+ if (!getSelectionPos(sel, &start, &end, &isRect, &rectStart, &rectEnd))
+ return;
+ if (isRect)
+@@ -2030,6 +2039,9 @@ static void replaceSelected(textBuffer *
+ {
+ int start, end, isRect, rectStart, rectEnd;
+ selection oldSelection = *sel;
++
++ /* silence bogus uninitialized variable warning from gcc 4.5 */
++ rectStart = rectEnd = 0;
+
+ /* If there's no selection, return */
+ if (!getSelectionPos(sel, &start, &end, &isRect, &rectStart, &rectEnd))
diff --git a/editors/nedit/patches/patch-source_textDisp.c b/editors/nedit/patches/patch-source_textDisp.c
new file mode 100644
index 00000000000..5d007fe4337
--- /dev/null
+++ b/editors/nedit/patches/patch-source_textDisp.c
@@ -0,0 +1,16 @@
+$NetBSD: patch-source_textDisp.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc 4.5 warnings about uninitialized variables.
+
+--- source/textDisp.c~ 2004-07-21 11:32:05.000000000 +0000
++++ source/textDisp.c
+@@ -1502,6 +1502,9 @@ static void bufModifiedCB(int pos, int n
+ int oldFirstChar = textD->firstChar;
+ int scrolled, origCursorPos = textD->cursorPos;
+ int wrapModStart, wrapModEnd;
++
++ /* silence bogus uninitialized variable warning from gcc 4.5 */
++ wrapModStart = wrapModEnd = -1;
+
+ /* buffer modification cancels vertical cursor motion column */
+ if (nInserted != 0 || nDeleted != 0)
diff --git a/editors/nedit/patches/patch-source_textDrag.c b/editors/nedit/patches/patch-source_textDrag.c
new file mode 100644
index 00000000000..060875e0956
--- /dev/null
+++ b/editors/nedit/patches/patch-source_textDrag.c
@@ -0,0 +1,17 @@
+$NetBSD: patch-source_textDrag.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc 4.5 warnings about uninitialized variables.
+
+--- source/textDrag.c~ 2004-07-21 11:32:05.000000000 +0000
++++ source/textDrag.c
+@@ -188,6 +188,10 @@ void BlockDragSelection(TextWidget tw, i
+ if (tw->text.dragState != PRIMARY_BLOCK_DRAG)
+ return;
+
++ /* gcc 4.5 warns that these are uninitialized, not clear if it's right */
++ tempModRangeEnd = -1;
++ bufModRangeEnd = -1;
++
+ /* The operation of block dragging is simple in theory, but not so simple
+ in practice. There is a backup buffer (tw->text.dragOrigBuf) which
+ holds a copy of the buffer as it existed before the drag. When the
diff --git a/editors/nedit/patches/patch-source_userCmds.c b/editors/nedit/patches/patch-source_userCmds.c
new file mode 100644
index 00000000000..af53c8ed94b
--- /dev/null
+++ b/editors/nedit/patches/patch-source_userCmds.c
@@ -0,0 +1,34 @@
+$NetBSD: patch-source_userCmds.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+Call <ctype.h> functions correctly.
+
+--- source/userCmds.c~ 2004-09-02 08:50:38.000000000 +0000
++++ source/userCmds.c
+@@ -1116,7 +1116,7 @@ static void dimSelDepItemsInMenu(Widget
+ XtVaGetValues(items[n], XmNsubMenuId, &subMenu, NULL);
+ dimSelDepItemsInMenu(subMenu, menuList, nMenuItems, sensitive);
+ } else {
+- index = (int)userData - 10;
++ index = (intptr_t)userData - 10;
+ if (index <0 || index >= nMenuItems)
+ return;
+ if (menuList[index]->input == FROM_SELECTION)
+@@ -2864,7 +2864,7 @@ static void generateAcceleratorString(ch
+ /* for a consistent look to the accelerator names in the menus,
+ capitalize the first letter of the keysym */
+ strcpy(keyName, XKeysymToString(keysym));
+- *keyName = toupper(*keyName);
++ *keyName = toupper((unsigned char)*keyName);
+
+ /* concatenate the strings together */
+ sprintf(text, "%s%s%s%s%s%s%s%s", shiftStr, ctrlStr, altStr,
+@@ -2946,7 +2946,7 @@ static int parseAcceleratorString(const
+ of the keysyms are "prettied up" by generateAcceleratorString */
+ *keysym = XStringToKeysym(fields[nFields-1]);
+ if (*keysym == NoSymbol) {
+- *fields[nFields-1] = tolower(*fields[nFields-1]);
++ *fields[nFields-1] = tolower((unsigned char)*fields[nFields-1]);
+ *keysym = XStringToKeysym(fields[nFields-1]);
+ if (*keysym == NoSymbol)
+ return False;
diff --git a/editors/nedit/patches/patch-source_window.c b/editors/nedit/patches/patch-source_window.c
new file mode 100644
index 00000000000..912d0d8e331
--- /dev/null
+++ b/editors/nedit/patches/patch-source_window.c
@@ -0,0 +1,28 @@
+$NetBSD: patch-source_window.c,v 1.1 2013/04/28 20:35:22 dholland Exp $
+
+Call XtVaSetValues correctly.
+
+--- source/window.c~ 2004-09-15 22:50:58.000000000 +0000
++++ source/window.c
+@@ -1157,7 +1157,7 @@ void SplitPane(WindowInfo *window)
+ if (window->backlightChars)
+ {
+ XtVaSetValues(text, textNbacklightCharTypes,
+- window->backlightCharTypes, 0);
++ window->backlightCharTypes, (char *)NULL);
+ }
+ XtManageChild(text);
+ window->textPanes[window->nPanes++] = text;
+@@ -3016,10 +3016,10 @@ void SetBacklightChars(WindowInfo *windo
+ window->backlightCharTypes = NULL;
+
+ XtVaSetValues(window->textArea,
+- textNbacklightCharTypes, window->backlightCharTypes, 0);
++ textNbacklightCharTypes, window->backlightCharTypes, (char *)NULL);
+ for (i=0; i<window->nPanes; i++)
+ XtVaSetValues(window->textPanes[i],
+- textNbacklightCharTypes, window->backlightCharTypes, 0);
++ textNbacklightCharTypes, window->backlightCharTypes, (char *)NULL);
+ if (is_applied != do_apply)
+ SetToggleButtonState(window, window->backlightCharsItem, do_apply, False);
+ }
diff --git a/editors/nedit/patches/patch-util_prefFile.c b/editors/nedit/patches/patch-util_prefFile.c
new file mode 100644
index 00000000000..07c4023f8ef
--- /dev/null
+++ b/editors/nedit/patches/patch-util_prefFile.c
@@ -0,0 +1,18 @@
+$NetBSD: patch-util_prefFile.c,v 1.1 2013/04/28 20:35:23 dholland Exp $
+
+Silence gcc warnings about unsafe pointer casts.
+
+--- util/prefFile.c~ 2004-07-21 11:32:07.000000000 +0000
++++ util/prefFile.c
+@@ -353,9 +353,9 @@ static int stringToPref(const char *stri
+ *(int *)rsrcDescrip->valueAddr = 0;
+ return False;
+ case PREF_STRING:
+- if ((int)strlen(string) >= (int)rsrcDescrip->arg)
++ if (strlen(string) >= (uintptr_t)rsrcDescrip->arg)
+ return False;
+- strncpy(rsrcDescrip->valueAddr, string, (int)rsrcDescrip->arg);
++ strncpy(rsrcDescrip->valueAddr, string, (uintptr_t)rsrcDescrip->arg);
+ return True;
+ case PREF_ALLOC_STRING:
+ *(char **)rsrcDescrip->valueAddr = XtMalloc(strlen(string) + 1);