SHA256
1
0
forked from pool/nedit
Files
nedit/nedit-5.5-null-pointers.patch

87 lines
3.4 KiB
Diff

--- source/text.c 2008/12/24 22:27:27 1.1
+++ source/text.c 2008/12/24 22:28:19
@@ -3126,7 +3126,7 @@
cancelDrag(w);
if (hasKey("scrollbar", args, nArgs)) {
XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
- XmNsliderSize, &sliderSize, 0);
+ XmNsliderSize, &sliderSize, NULL);
horizOffset = min(textD->horizOffset + textD->width, sliderMax - sliderSize);
if (textD->horizOffset == horizOffset) {
ringIfNecessary(silent, w);
@@ -3218,7 +3218,7 @@
if (*nArgs == 0 || sscanf(args[0], "%d", &nPixels) != 1)
return;
XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
- XmNsliderSize, &sliderSize, 0);
+ XmNsliderSize, &sliderSize, NULL);
horizOffset = min(max(0, textD->horizOffset - nPixels), sliderMax - sliderSize);
if (textD->horizOffset != horizOffset) {
TextDSetScroll(textD, textD->topLineNum, horizOffset);
@@ -3235,7 +3235,7 @@
if (*nArgs == 0 || sscanf(args[0], "%d", &nPixels) != 1)
return;
XtVaGetValues(textD->hScrollBar, XmNmaximum, &sliderMax,
- XmNsliderSize, &sliderSize, 0);
+ XmNsliderSize, &sliderSize, NULL);
horizOffset = min(max(0, textD->horizOffset + nPixels), sliderMax - sliderSize);
if (textD->horizOffset != horizOffset) {
TextDSetScroll(textD, textD->topLineNum, horizOffset);
--- source/search.c 2008/12/24 22:26:53 1.1
+++ source/search.c 2008/12/24 22:27:17
@@ -1042,7 +1042,7 @@
XtAddCallback(replaceBtn, XmNactivateCallback, (XtCallbackProc)replaceCB, window);
XmStringFree(st1);
XtManageChild(replaceBtn);
- XtVaGetValues(replaceBtn, XmNshadowThickness, &shadowThickness, 0);
+ XtVaGetValues(replaceBtn, XmNshadowThickness, &shadowThickness, NULL);
defaultBtnOffset = shadowThickness + 4;
argcnt = 0;
--- source/window.c 2008/12/24 22:28:23 1.1
+++ source/window.c 2008/12/24 22:29:03
@@ -1157,7 +1157,7 @@
if (window->backlightChars)
{
XtVaSetValues(text, textNbacklightCharTypes,
- window->backlightCharTypes, 0);
+ window->backlightCharTypes, NULL);
}
XtManageChild(text);
window->textPanes[window->nPanes++] = text;
@@ -3016,10 +3016,10 @@
window->backlightCharTypes = NULL;
XtVaSetValues(window->textArea,
- textNbacklightCharTypes, window->backlightCharTypes, 0);
+ textNbacklightCharTypes, window->backlightCharTypes, NULL);
for (i=0; i<window->nPanes; i++)
XtVaSetValues(window->textPanes[i],
- textNbacklightCharTypes, window->backlightCharTypes, 0);
+ textNbacklightCharTypes, window->backlightCharTypes, NULL);
if (is_applied != do_apply)
SetToggleButtonState(window, window->backlightCharsItem, do_apply, False);
}
--- source/menu.c 2008/12/24 22:34:34 1.1
+++ source/menu.c 2008/12/24 22:34:44
@@ -1254,7 +1254,7 @@
HidePointerOnKeyedEvent(WidgetToWindow(MENU_WIDGET(menuItem))->lastFocus,
((XmAnyCallbackStruct *)callData)->event);
- XtVaGetValues( menuItem, XmNuserData, &topic, 0 );
+ XtVaGetValues( menuItem, XmNuserData, &topic, NULL );
Help(topic);
}
--- source/menu.c 2008/12/24 23:16:55 1.1
+++ source/menu.c 2008/12/24 23:17:17
@@ -1242,7 +1242,7 @@
Widget menuItem =
createMenuItem( parent, name, label, mnemonic, callback, cbArg, mode );
- XtVaSetValues( menuItem, XmNuserData, topic, 0 );
+ XtVaSetValues( menuItem, XmNuserData, topic, NULL );
return menuItem;
}