From 4312a1190b18e962ffedefd1d48bddebec11e0f7 Mon Sep 17 00:00:00 2001 From: Jon Trulson Date: Mon, 24 Mar 2014 18:26:10 -0600 Subject: [PATCH] cleanup: eliminate missing sentinel warnings --- cde/lib/tt/lib/tttk/ttdesktop.C | 4 ++-- cde/programs/dtcm/dtcm/deskset.c | 2 +- cde/programs/dtcm/dtcm/props_pu.c | 2 +- .../ksh93/src/lib/libast/misc/procopen.c | 2 +- cde/programs/dtmail/MotifApp/MainWindow.C | 2 +- cde/programs/dtmail/dtmail/DialogShell.C | 2 +- cde/programs/dtudcfonted/cpyw.c | 4 ++-- cde/programs/dtudcfonted/mtfgui.c | 8 +++---- cde/programs/ttsnoop/patternProps_stubs.C.src | 10 ++++----- .../ttsnoop/sessionChooser_stubs.C.src | 12 +++++----- .../ttsnoop/stringChooser_stubs.C.src | 12 +++++----- cde/programs/ttsnoop/ttChooser_stubs.C.src | 22 +++++++++---------- 12 files changed, 41 insertions(+), 41 deletions(-) diff --git a/cde/lib/tt/lib/tttk/ttdesktop.C b/cde/lib/tt/lib/tttk/ttdesktop.C index 6a38af26..11a2cbf2 100644 --- a/cde/lib/tt/lib/tttk/ttdesktop.C +++ b/cde/lib/tt/lib/tttk/ttdesktop.C @@ -184,7 +184,7 @@ _ttdt_realized_widget( } Boolean mappedWhenManaged = False; CALLXT(XtVaGetValues)( _widget, - XtNmappedWhenManaged, &mappedWhenManaged, 0 ); + XtNmappedWhenManaged, &mappedWhenManaged, NULL ); if (! mappedWhenManaged) { return 0; } @@ -838,7 +838,7 @@ _ttdt_is_iconic( { Boolean iconic; // XXX XtNiconic always returns false?! - CALLXT(XtVaGetValues)( widget, XtNiconic, &iconic, 0 ); + CALLXT(XtVaGetValues)( widget, XtNiconic, &iconic, NULL ); return (iconic == TRUE); } diff --git a/cde/programs/dtcm/dtcm/deskset.c b/cde/programs/dtcm/dtcm/deskset.c index 17fb20aa..f861a08e 100644 --- a/cde/programs/dtcm/dtcm/deskset.c +++ b/cde/programs/dtcm/dtcm/deskset.c @@ -253,7 +253,7 @@ ds_force_popup_on_screen(Widget popup, int *popup_x_p, int *popup_y_p) { XtVaSetValues(popup, XmNx, left, XmNy, top, - 0) ; + NULL) ; if (popup_x != *popup_x_p || popup_y != *popup_y_p) rcode = TRUE ; else rcode = FALSE ; diff --git a/cde/programs/dtcm/dtcm/props_pu.c b/cde/programs/dtcm/dtcm/props_pu.c index 747ca9c7..f7ff7f2d 100644 --- a/cde/programs/dtcm/dtcm/props_pu.c +++ b/cde/programs/dtcm/dtcm/props_pu.c @@ -277,7 +277,7 @@ p_create_editor_pane( } } - XtVaGetValues(pu->ep_dur_cb, XmNtextField, &text_field, 0); + XtVaGetValues(pu->ep_dur_cb, XmNtextField, &text_field, NULL); XtAddCallback(text_field, XmNvalueChangedCallback, p_mark_change, pu); XtAddCallback(pu->ep_dur_cb, XmNselectionCallback, p_mark_change, pu); diff --git a/cde/programs/dtksh/ksh93/src/lib/libast/misc/procopen.c b/cde/programs/dtksh/ksh93/src/lib/libast/misc/procopen.c index 0b35172f..a1402197 100644 --- a/cde/programs/dtksh/ksh93/src/lib/libast/misc/procopen.c +++ b/cde/programs/dtksh/ksh93/src/lib/libast/misc/procopen.c @@ -503,7 +503,7 @@ procopen __PARAM__((const char* cmd, char** argv, char** envv, long* modv, long if (!fork()) { sfsprintf(path, sizeof(path), "%d", getppid()); - execlp("trace", "trace", "-p", path, NiL); + execlp("trace", "trace", "-p", path, NULL); _exit(EXIT_NOTFOUND); } sleep(2); diff --git a/cde/programs/dtmail/MotifApp/MainWindow.C b/cde/programs/dtmail/MotifApp/MainWindow.C index 1065b338..4ec2dd9f 100644 --- a/cde/programs/dtmail/MotifApp/MainWindow.C +++ b/cde/programs/dtmail/MotifApp/MainWindow.C @@ -130,7 +130,7 @@ MainWindow::initialize( ) theApplication->baseWidget(), XmNdeleteResponse, XmDO_NOTHING, XmNallowShellResize, _allow_resize, - NULL, 0 ); + NULL, NULL ); #ifdef USE_EDITRES XtAddEventHandler( diff --git a/cde/programs/dtmail/dtmail/DialogShell.C b/cde/programs/dtmail/dtmail/DialogShell.C index 7196d037..12bf3f6f 100644 --- a/cde/programs/dtmail/dtmail/DialogShell.C +++ b/cde/programs/dtmail/dtmail/DialogShell.C @@ -94,7 +94,7 @@ DialogShell::initialize() _w = XtVaCreatePopupShell( _name, _widgetClass, _parent->baseWidget(), XmNdefaultPosition, False, - NULL, 0 ); + NULL, NULL ); #ifdef USE_EDITRES XtAddEventHandler( _w, (EventMask) 0, True, diff --git a/cde/programs/dtudcfonted/cpyw.c b/cde/programs/dtudcfonted/cpyw.c index fd0dbfd2..10227d6b 100644 --- a/cde/programs/dtudcfonted/cpyw.c +++ b/cde/programs/dtudcfonted/cpyw.c @@ -294,7 +294,7 @@ Widget owner; Widget delNoticeW = NULL; delNoticeW = CreateDelNotice(owner); - XtVaSetValues(XtParent(delNoticeW), XmNmappedWhenManaged, False, 0); + XtVaSetValues(XtParent(delNoticeW), XmNmappedWhenManaged, False, NULL); XtManageChild(delNoticeW); for ( i=0 ; i < dn.disp_num ; i++ ) { @@ -304,7 +304,7 @@ Widget owner; drawDelCode(i); drawDelPtn(i); } - XtVaSetValues(XtParent(delNoticeW), XmNmappedWhenManaged, True, 0); + XtVaSetValues(XtParent(delNoticeW), XmNmappedWhenManaged, True, NULL); XBell(XtDisplayOfObject(delNoticeW), 0); } diff --git a/cde/programs/dtudcfonted/mtfgui.c b/cde/programs/dtudcfonted/mtfgui.c index 5d3c8c4c..08d40812 100644 --- a/cde/programs/dtudcfonted/mtfgui.c +++ b/cde/programs/dtudcfonted/mtfgui.c @@ -183,7 +183,7 @@ int i; XtVaSetValues( wgeStaT_list[i], XmNbackground, (XtArgVal) resource.foreground, XmNforeground, (XtArgVal) resource.background, - 0); + NULL); xl.list_winID = XtWindow( wgeStaT_disp[i] ) ; } @@ -194,8 +194,8 @@ int i; XtVaSetValues( wgeStaT_list[i], XmNbackground, (XtArgVal) resource.background, XmNforeground, (XtArgVal) resource.foreground, - 0); - xl.list_winID = NULL ; + NULL); + xl.list_winID = 0 ; } void @@ -505,7 +505,7 @@ Widget owner; } /* create the scroll bar for Charcter list */ - XtVaGetValues( listBase, XmNheight, &(edlist.list_h), 0); + XtVaGetValues( listBase, XmNheight, &(edlist.list_h), NULL); if (( slimax = efctPtnNum()) < edlist.nlist) slimax = edlist.nlist; diff --git a/cde/programs/ttsnoop/patternProps_stubs.C.src b/cde/programs/ttsnoop/patternProps_stubs.C.src index 4ca4f9c0..aded915a 100644 --- a/cde/programs/ttsnoop/patternProps_stubs.C.src +++ b/cde/programs/ttsnoop/patternProps_stubs.C.src @@ -59,7 +59,7 @@ patternProps2Pat( { Tt_pattern pat; XtVaGetValues( instance->patternProps_shellform, - XmNuserData, &pat, 0 ); + XmNuserData, &pat, NULL ); return pat; } @@ -96,7 +96,7 @@ _DtTtPatternWidgetUpdate( if (tt_is_err( status )) { printout = tt_status_message( status ); } - XtVaSetValues( instance->patternText, XmNvalue, printout, 0 ); + XtVaSetValues( instance->patternText, XmNvalue, printout, NULL ); _DtTtPatternSetUpdating( pat, True ); @@ -119,7 +119,7 @@ _DtTtPatternWidgetUpdate( choice = instance->categoryChoice_items.HANDLE_ROTATE_item; break; } - XtVaSetValues( instance->categoryChoice, XmNmenuHistory, choice, 0 ); + XtVaSetValues( instance->categoryChoice, XmNmenuHistory, choice, NULL ); _DtTtPatternSetUpdating( pat, False ); } @@ -356,7 +356,7 @@ DtTtPatternWidgetCreate( dtb_pattern_props_pattern_props_initialize( instance, parent ); widget = instance->patternProps; - XtVaSetValues( instance->patternProps_shellform, XmNuserData, pat, 0 ); + XtVaSetValues( instance->patternProps_shellform, XmNuserData, pat, NULL ); status = tt_pattern_user_set( pat, DtTtPatWidgetKey, widget ); if (tt_is_err( status )) { XtDestroyWidget( widget ); @@ -375,7 +375,7 @@ DtTtPatternWidgetCreate( labelStream << "Tt_pattern " << (void *)pat << ends; XtVaSetValues( instance->patternProps, XmNtitle, labelStream.str(), - 0 ); + NULL ); delete labelStream.str(); _DtTtPatternWidgetUpdate( instance, pat ); diff --git a/cde/programs/ttsnoop/sessionChooser_stubs.C.src b/cde/programs/ttsnoop/sessionChooser_stubs.C.src index cc956297..cc3fde27 100644 --- a/cde/programs/ttsnoop/sessionChooser_stubs.C.src +++ b/cde/programs/ttsnoop/sessionChooser_stubs.C.src @@ -98,10 +98,10 @@ _DtSessionChooserSet( instance, dtb_ttsnoop_ttsnoop_win.ttsnoopWin ); } DtTtSetLabel( instance->sessionOkButton, okString ); - XtVaSetValues( instance->sessionChooser, XmNtitle, title, 0 ); + XtVaSetValues( instance->sessionChooser, XmNtitle, title, NULL ); // Remember dialog mode, entity - XtVaSetValues( instance->sessionOkButton, XmNuserData, choice, 0 ); - XtVaSetValues( instance->sessionCancelButton, XmNuserData, entity, 0 ); + XtVaSetValues( instance->sessionOkButton, XmNuserData, choice, NULL ); + XtVaSetValues( instance->sessionCancelButton, XmNuserData, entity, NULL ); XmTextPosition last = XmTextFieldGetLastPosition( instance->sessionText ); Time when = @@ -209,9 +209,9 @@ sessionOK( session = 0; } XtPointer val; - XtVaGetValues( instance->sessionOkButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->sessionOkButton, XmNuserData, &val, NULL ); _DtSessionChooserAction choice = (_DtSessionChooserAction) (long) val; - XtVaGetValues( instance->sessionCancelButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->sessionCancelButton, XmNuserData, &val, NULL ); Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { Tt_status status; @@ -267,7 +267,7 @@ sessionHelp( DtbSessionChooserSessionChooserInfo instance = (DtbSessionChooserSessionChooserInfo)clientData; XtPointer val; - XtVaGetValues( instance->sessionOkButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->sessionOkButton, XmNuserData, &val, NULL ); _DtSessionChooserAction choice = (_DtSessionChooserAction) (long) val; Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { diff --git a/cde/programs/ttsnoop/stringChooser_stubs.C.src b/cde/programs/ttsnoop/stringChooser_stubs.C.src index 59ded2e6..daef6031 100644 --- a/cde/programs/ttsnoop/stringChooser_stubs.C.src +++ b/cde/programs/ttsnoop/stringChooser_stubs.C.src @@ -182,10 +182,10 @@ _DtStringChooserSet( } DtTtSetLabel( instance->stringOkButton, okString ); DtTtSetLabel( instance->stringText_label, valueLabel ); - XtVaSetValues( instance->stringChooser, XmNtitle, title, 0 ); + XtVaSetValues( instance->stringChooser, XmNtitle, title, NULL ); // Remember dialog mode, entity - XtVaSetValues( instance->stringOkButton, XmNuserData, choice, 0 ); - XtVaSetValues( instance->stringCancelButton, XmNuserData, entity, 0 ); + XtVaSetValues( instance->stringOkButton, XmNuserData, choice, NULL ); + XtVaSetValues( instance->stringCancelButton, XmNuserData, entity, NULL ); XmTextPosition last = XmTextFieldGetLastPosition( instance->stringText ); Time when = XtLastTimestampProcessed( XtDisplay( instance->stringText )); XmTextFieldSetSelection( instance->stringText, 0, last, when ); @@ -242,9 +242,9 @@ stringOkayed( string = 0; } XtPointer val; - XtVaGetValues( instance->stringOkButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->stringOkButton, XmNuserData, &val, NULL ); _DtStringChooserAction choice = (_DtStringChooserAction) (long) val; - XtVaGetValues( instance->stringCancelButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->stringCancelButton, XmNuserData, &val, NULL ); Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { Tt_status status; @@ -327,7 +327,7 @@ stringHelp( DtbStringChooserStringChooserInfo instance = (DtbStringChooserStringChooserInfo)clientData; XtPointer val; - XtVaGetValues( instance->stringOkButton, XmNuserData, &val, 0 ); + XtVaGetValues( instance->stringOkButton, XmNuserData, &val, NULL ); _DtStringChooserAction choice = (_DtStringChooserAction) (long) val; Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { diff --git a/cde/programs/ttsnoop/ttChooser_stubs.C.src b/cde/programs/ttsnoop/ttChooser_stubs.C.src index 2592b3a6..ed0f854a 100644 --- a/cde/programs/ttsnoop/ttChooser_stubs.C.src +++ b/cde/programs/ttsnoop/ttChooser_stubs.C.src @@ -208,10 +208,10 @@ _DtTtChooserSet( XtVaSetValues( instance->chooserList, XmNitemCount, itemCount, XmNitems, items, - 0 ); + NULL ); XmListDeselectAllItems( instance->chooserList ); XmTextFieldSetString( instance->chooserText, 0 ); - XtVaSetValues( instance->chooser, XmNtitle, title, 0 ); + XtVaSetValues( instance->chooser, XmNtitle, title, NULL ); std::ostrstream valuesStream; valuesStream << itemCount << " " << valuesLabel; @@ -221,8 +221,8 @@ _DtTtChooserSet( delete valuesStream.str(); // Remember dialog mode, entity - XtVaSetValues( instance->chooserOkButton, XmNuserData, choice, 0 ); - XtVaSetValues( instance->chooserCancelButton, XmNuserData, entity, 0 ); + XtVaSetValues( instance->chooserOkButton, XmNuserData, choice, NULL ); + XtVaSetValues( instance->chooserCancelButton, XmNuserData, entity, NULL ); XtManageChild( instance->chooser_shellform ); } @@ -272,7 +272,7 @@ choiceSelected( DtbTtChooserChooserInfo instance = (DtbTtChooserChooserInfo)clientData; XmListCallbackStruct *info = (XmListCallbackStruct *)callData; int choice; - XtVaGetValues( instance->chooserOkButton, XmNuserData, &choice, 0 ); + XtVaGetValues( instance->chooserOkButton, XmNuserData, &choice, NULL ); DtTtType type; Boolean isString = False; switch ((_DtTtChooserAction)choice) { @@ -340,7 +340,7 @@ choiceOkayed( DtbTtChooserChooserInfo instance = (DtbTtChooserChooserInfo)clientData; char *text = XmTextFieldGetString( instance->chooserText ); int ival; - XtVaGetValues( instance->chooserOkButton, XmNuserData, &ival, 0 ); + XtVaGetValues( instance->chooserOkButton, XmNuserData, &ival, NULL ); _DtTtChooserAction choice = (_DtTtChooserAction)ival; Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { @@ -374,25 +374,25 @@ choiceOkayed( break; case _DtTtChooserMessageOpSet: XtVaGetValues( instance->chooserCancelButton, - XmNuserData, &xtPtr, 0 ); + XmNuserData, &xtPtr, NULL ); _DtTtMessageUpdate( (Tt_message)xtPtr, choice, text ); XtUnmanageChild( instance->chooser_shellform ); break; case _DtTtChooserPatternOpAdd: XtVaGetValues( instance->chooserCancelButton, - XmNuserData, &xtPtr, 0 ); + XmNuserData, &xtPtr, NULL ); _DtTtPatternUpdate( (Tt_pattern)xtPtr, choice, text ); XtUnmanageChild( instance->chooser_shellform ); break; case _DtTtChooserMessageHandlerSet: XtVaGetValues( instance->chooserCancelButton, - XmNuserData, &xtPtr, 0 ); + XmNuserData, &xtPtr, NULL ); _DtTtMessageUpdate( (Tt_message)xtPtr, choice, text ); XtUnmanageChild( instance->chooser_shellform ); break; case _DtTtChooserPatternSenderAdd: XtVaGetValues( instance->chooserCancelButton, - XmNuserData, &xtPtr, 0 ); + XmNuserData, &xtPtr, NULL ); _DtTtPatternUpdate( (Tt_pattern)xtPtr, choice, text ); XtUnmanageChild( instance->chooser_shellform ); break; @@ -592,7 +592,7 @@ ttChooserHelp( /*** DTB_USER_CODE_START vvv Add C code below vvv ***/ DtbTtChooserChooserInfo instance = (DtbTtChooserChooserInfo)clientData; int ival; - XtVaGetValues( instance->chooserOkButton, XmNuserData, &ival, 0 ); + XtVaGetValues( instance->chooserOkButton, XmNuserData, &ival, NULL ); _DtTtChooserAction choice = (_DtTtChooserAction)ival; Widget label = dtb_ttsnoop_ttsnoop_win.ttsnoopWin_label; switch (choice) { -- 2.25.1