dtappbuilder: Resolve all compiler warnings
authorPeter Howkins <flibble@users.sf.net>
Tue, 24 Apr 2018 20:55:56 +0000 (21:55 +0100)
committerPeter Howkins <flibble@users.sf.net>
Tue, 24 Apr 2018 20:55:56 +0000 (21:55 +0100)
79 files changed:
cde/programs/dtappbuilder/src/ab/ab_utils.c
cde/programs/dtappbuilder/src/ab/abobj_events.c
cde/programs/dtappbuilder/src/ab/abobj_resize.c
cde/programs/dtappbuilder/src/ab/abobj_select.c
cde/programs/dtappbuilder/src/ab/about_box_stubs.c
cde/programs/dtappbuilder/src/ab/appfw_stubs.c
cde/programs/dtappbuilder/src/ab/attch_ed_stubs.c
cde/programs/dtappbuilder/src/ab/brws.c
cde/programs/dtappbuilder/src/ab/brws_mthds.c
cde/programs/dtappbuilder/src/ab/brws_stubs.c
cde/programs/dtappbuilder/src/ab/button_stubs.c
cde/programs/dtappbuilder/src/ab/cgen_env_stubs.c
cde/programs/dtappbuilder/src/ab/cgen_props_stubs.c
cde/programs/dtappbuilder/src/ab/cgen_utils.c
cde/programs/dtappbuilder/src/ab/cgen_win_stubs.c
cde/programs/dtappbuilder/src/ab/choice_stubs.c
cde/programs/dtappbuilder/src/ab/color_chooser_stubs.c
cde/programs/dtappbuilder/src/ab/combobox_stubs.c
cde/programs/dtappbuilder/src/ab/conn_stubs.c
cde/programs/dtappbuilder/src/ab/cpanel_stubs.c
cde/programs/dtappbuilder/src/ab/custdlg_stubs.c
cde/programs/dtappbuilder/src/ab/dnd_ed_stubs.c
cde/programs/dtappbuilder/src/ab/drawp_stubs.c
cde/programs/dtappbuilder/src/ab/dtbuilder.c.src
cde/programs/dtappbuilder/src/ab/fchooser_stubs.c
cde/programs/dtappbuilder/src/ab/group_stubs.c
cde/programs/dtappbuilder/src/ab/help_ed_stubs.c
cde/programs/dtappbuilder/src/ab/label_stubs.c
cde/programs/dtappbuilder/src/ab/list_stubs.c
cde/programs/dtappbuilder/src/ab/mainwin_stubs.c
cde/programs/dtappbuilder/src/ab/menu_stubs.c
cde/programs/dtappbuilder/src/ab/menubar_stubs.c
cde/programs/dtappbuilder/src/ab/message_ed_stubs.c
cde/programs/dtappbuilder/src/ab/pal.c
cde/programs/dtappbuilder/src/ab/pal_combobox.c
cde/programs/dtappbuilder/src/ab/pal_create.c
cde/programs/dtappbuilder/src/ab/pal_custdlg.c
cde/programs/dtappbuilder/src/ab/pal_group.c
cde/programs/dtappbuilder/src/ab/pal_list.c
cde/programs/dtappbuilder/src/ab/pal_mainwin.c
cde/programs/dtappbuilder/src/ab/pal_menu.c
cde/programs/dtappbuilder/src/ab/pal_scale.c
cde/programs/dtappbuilder/src/ab/pal_termp.c
cde/programs/dtappbuilder/src/ab/pal_textf.c
cde/programs/dtappbuilder/src/ab/pal_textp.c
cde/programs/dtappbuilder/src/ab/palette_stubs.c
cde/programs/dtappbuilder/src/ab/panedwin_ed_stubs.c
cde/programs/dtappbuilder/src/ab/proj_stubs.c
cde/programs/dtappbuilder/src/ab/revolv_stubs.c
cde/programs/dtappbuilder/src/ab/scale_stubs.c
cde/programs/dtappbuilder/src/ab/sep_stubs.c
cde/programs/dtappbuilder/src/ab/spinbox_stubs.c
cde/programs/dtappbuilder/src/ab/termp_stubs.c
cde/programs/dtappbuilder/src/ab/textf_stubs.c
cde/programs/dtappbuilder/src/ab/textp_stubs.c
cde/programs/dtappbuilder/src/ab/ui_msg.c
cde/programs/dtappbuilder/src/ab/ui_util.c
cde/programs/dtappbuilder/src/abmf/abmfP.h
cde/programs/dtappbuilder/src/abmf/args.c
cde/programs/dtappbuilder/src/abmf/create_decls.c
cde/programs/dtappbuilder/src/abmf/instances.c
cde/programs/dtappbuilder/src/abmf/lib_func_strings.c
cde/programs/dtappbuilder/src/abmf/lib_funcs.c
cde/programs/dtappbuilder/src/abmf/stubs_c_file.c
cde/programs/dtappbuilder/src/abmf/write_c.c
cde/programs/dtappbuilder/src/libABil/abuil_load.c
cde/programs/dtappbuilder/src/libABil/abuil_print.c
cde/programs/dtappbuilder/src/libABil/abuil_resource_attr_map.c
cde/programs/dtappbuilder/src/libABil/abuil_trav.c
cde/programs/dtappbuilder/src/libABil/bil.c
cde/programs/dtappbuilder/src/libABil/bil_lexer.c
cde/programs/dtappbuilder/src/libABil/bil_loadfile.c
cde/programs/dtappbuilder/src/libABobj/obj.c
cde/programs/dtappbuilder/src/libABobj/obj_notify.c
cde/programs/dtappbuilder/src/libABobj/obj_utils.c
cde/programs/dtappbuilder/src/libABobjXm/objxm_config.c
cde/programs/dtappbuilder/src/libABobjXm/objxm_strs.c
cde/programs/dtappbuilder/src/libAButil/istr.c
cde/programs/dtappbuilder/src/libAButil/util_file.c

index 6a2c4af41a471229390b5a4e2fd72318bd014a34..ea629b60da5593da1d1e819c723ac7a8ae3cfea9 100644 (file)
@@ -786,12 +786,12 @@ ab_set_busy_cursor(
     ABWindow   *win;
     ABObj       module;
     ABObj       winobj;
-    static      Cursor busy_cursor = NULL;
-    Cursor      new_cursor = NULL;
+    static      Cursor busy_cursor = 0;
+    Cursor      new_cursor = 0;
     int         num_wins;
     int         i;
 
-    if (busy_cursor == NULL)
+    if (busy_cursor == 0)
         busy_cursor = XCreateFontCursor(XtDisplay(AB_toplevel), XC_watch);
 
     if (on)
@@ -1001,7 +1001,7 @@ ab_is_cur_dir(STRING dir)
         ab_get_cur_dir();       /* initialize it! */
     }
  
-    if ((dir == NULL) || (*dir == NULL) || (*dir == '.'))
+    if ((dir == NULL) || (*dir == 0) || (*dir == '.'))
     {
         return TRUE;
     }
index 73b7a899de9246b7dd6c279dc64999781508f650..9c51d80d06a27f88bc7a5ccf846c9de3fe5ebba2 100644 (file)
@@ -901,7 +901,7 @@ initiate_move(
     ABObj              geomObj;
     Widget             geomWidget;
     Widget             parent;
-    static Cursor      move_cursor = NULL;
+    static Cursor      move_cursor = 0;
 
     rootObj = obj_get_root(obj);
 
@@ -963,7 +963,7 @@ initiate_resize(
  
     if (XtGrabPointer(widget, False,
         ButtonReleaseMask | ButtonMotionMask | PointerMotionMask,
-        GrabModeAsync, GrabModeAsync,  NULL,
+        GrabModeAsync, GrabModeAsync,  0,
             resize_cursor, CurrentTime) == GrabSuccess)
  
         return OK;
@@ -1098,7 +1098,7 @@ interpose_button_event(
     XMotionEvent               *mevent;
     static XEvent              event_cpy;
     static DoubleClickInfo     *d_click = NULL;
-    static XtIntervalId                timer_id = NULL;
+    static XtIntervalId                timer_id = 0;
     ABObj                      obj = (ABObj)client_data;
     ABObj                      moveObj;
     
index 5ca15add3f40b1619a90cdd2cb2ebbbe14eab9bf..a750d31c1558ad1fc855ef73bac781bbc065acce 100644 (file)
@@ -290,8 +290,8 @@ abobjP_get_resize_cursor(
 )
 {
     static Cursor    resize_cursor[10] = 
-                       { NULL, NULL, NULL, NULL, NULL
-                          NULL, NULL, NULL, NULL, NULL };
+                       { 0, 0, 0, 0, 0
+                          0, 0, 0, 0, 0 };
     unsigned int     shape;
 
     if (!resize_cursor[dir])
@@ -332,7 +332,7 @@ abobjP_get_resize_cursor(
                    break;
                case NONE:
                 default:
-                   return NULL;
+                   return 0;
            }
             resize_cursor[dir] = XCreateFontCursor(XtDisplay(w), shape);
        }
index 2d34f1eff33d1438dc05e2ca5c31f3e7afbb22bb..13171415a4d6c227980700644c15488ddecb4d6d 100644 (file)
@@ -48,6 +48,7 @@
  *
  ***********************************************************************
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <X11/Intrinsic.h>
 #include <X11/cursorfont.h>
@@ -452,7 +453,7 @@ turnon_select_feedback(
     draw_select_feedback(selObj, resizable);
 
     XtAddEventHandler(selWidget, StructureNotifyMask | ExposureMask, FALSE,
-               select_feedback_redraw, (XtPointer)resizable);
+               select_feedback_redraw, (XtPointer)(uintptr_t) resizable);
 
     XtAddEventHandler(selWidget, PointerMotionMask, FALSE,
                 monitor_cursor, (XtPointer)selObj);
@@ -480,7 +481,7 @@ turnoff_select_feedback(
     x_get_widget_rect(selWidget, &w_rect);
 
     XtRemoveEventHandler(selWidget, StructureNotifyMask | ExposureMask, FALSE,
-                select_feedback_redraw, (XtPointer)resizable);
+                select_feedback_redraw, (XtPointer)(uintptr_t) resizable);
 
     XtRemoveEventHandler(selWidget, PointerMotionMask, FALSE,
                 monitor_cursor, (XtPointer)selObj);
@@ -667,7 +668,7 @@ monitor_cursor(
     }
     else
     {
-       if ((resize_cursor = abobjP_get_resize_cursor(selWidget, dir)) != NULL)
+       if ((resize_cursor = abobjP_get_resize_cursor(selWidget, dir)) != 0)
        {
            XDefineCursor(dpy, win, resize_cursor);
            cursor_changed = TRUE;
@@ -688,7 +689,7 @@ select_feedback_redraw(
 )
 {
     ABObj      selObj = NULL;
-    BOOL       resizable = (BOOL)((unsigned int)clientdata);
+    BOOL       resizable = (BOOL)((uintptr_t) clientdata);
     Boolean     redraw = FALSE;
 
     selObj = objxm_get_obj_from_widget(selWidget);
index 0ada81de806d6e9e0e5301fa9feb7ddaff348dc6..90b371aede898cc4294d8b065b8f6aad2ac581c1 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 706b9324dedaebd63a01298ddf7cb48663a4183d..fadbc02f58d6bd78724202ce6de9565694ffd729 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -194,7 +195,7 @@ appfw_editor_init(
        /* Primary Main Window */
         n = 0;
         item[n] = appfw_cgen->rootwin_opmenu_items.None_item;
-        item_val[n] = NULL; n++;
+        item_val[n] = 0; n++;
         prop_obj_options_init(&(afs->rootwin), appfw_cgen->rootwin_label,
                 appfw_cgen->rootwin_opmenu, appfw_cgen->rootwin_opmenu_menu,
                 n, item, (XtPointer*)item_val,
index bbea9ccf280d2f48cddd0c47617e6253106d1dc9..9617fcba7c142a57f142b375a3389cae0cc08707 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -853,7 +854,7 @@ load_attch_obj(
        &(ats->left_attach_obj), 
        left_offset, 
        left_position, 
-       (int)left_obj);
+       left_obj);
 
     set_attach_values(right_attach_type, 
        &(ats->right_attach_offset), 
@@ -861,7 +862,7 @@ load_attch_obj(
        &(ats->right_attach_obj), 
        right_offset, 
        right_position, 
-       (int)right_obj);
+       right_obj);
 
     set_attach_values(top_attach_type, 
        &(ats->top_attach_offset), 
@@ -869,7 +870,7 @@ load_attch_obj(
        &(ats->top_attach_obj), 
        top_offset, 
        top_position, 
-       (int)top_obj);
+       top_obj);
 
     set_attach_values(bottom_attach_type, 
        &(ats->bottom_attach_offset), 
@@ -877,7 +878,7 @@ load_attch_obj(
        &(ats->bottom_attach_obj), 
        bottom_offset, 
        bottom_position, 
-       (int)bottom_obj);
+       bottom_obj);
 
     /*
      * Set object name
@@ -1281,12 +1282,12 @@ get_attach_info(
         case AB_ATTACH_GRIDLINE:
            *type = ATTCH_ED_GRIDLINE;
             *offset = attachment->offset;
-            *position = (int)attachment->value;
+            *position = (int)(intptr_t) attachment->value;
         break;
 
         case AB_ATTACH_CENTER_GRIDLINE:
            *type = ATTCH_ED_CENTER_GRIDLINE;
-            *position = (int)attachment->value;
+            *position = (int)(intptr_t) attachment->value;
             *offset = 0;
         break;
 
@@ -1343,13 +1344,13 @@ set_attach_info(
 
     case ATTCH_ED_GRIDLINE:
        attachment->type = AB_ATTACH_GRIDLINE;
-        attachment->value = (void *)position;
+        attachment->value = (void *)(intptr_t) position;
         attachment->offset = offset;
     break;
 
     case ATTCH_ED_CENTER_GRIDLINE:
        attachment->type = AB_ATTACH_CENTER_GRIDLINE;
-        attachment->value = (void *)position;
+        attachment->value = (void *)(intptr_t) position;
         attachment->offset = 0;
     break;
 
@@ -1572,7 +1573,7 @@ create_obj_menu_dir(
                                menu,
                                changebar,
                                *item = NULL;
-    int                                item_values = NULL,
+    int                                item_values = 0,
                                *item_val = NULL, 
                                n = 0;
 
@@ -1636,7 +1637,7 @@ create_obj_menu_dir(
      * first one
      */
     if (n > 0)
-        prop_options_set_value(option_setting, (XtPointer)item_val[0], False);
+        prop_options_set_value(option_setting, (XtPointer)(uintptr_t) item_val[0], False);
 
     if (item)
        util_free(item);
@@ -2353,7 +2354,7 @@ change_attype_from_sib_to_point(
                        &offset, &position);
        
         obj_set_attachment(obj, dir, AB_ATTACH_POINT, 
-                           (void *)position, offset);
+                           (void *)(uintptr_t) position, offset);
         objxm_obj_set_attachment_args(obj, OBJXM_CONFIG_BUILD);
     }
 }
index cfbfb2a59b3b7c9e28b6a98ed5c2d16f1a9c9278..cf7c7bbecd320372f41a88978e996472171cfb48 100644 (file)
@@ -1839,7 +1839,7 @@ setup_vwr_graphics(
 
     if (!ui_handle->bg_font) 
     {
-       Font    font = NULL;
+       Font    font = 0;
 
         XtVaGetValues(draw_area, XtNfont, &font, NULL);
         ui_handle->bg_font = (XFontStruct *)XQueryFont(dpy, font);
@@ -2306,8 +2306,8 @@ aob_create_ui_obj
     ui->line_gc = NULL;
     ui->sm_font = NULL;
     ui->bg_font = NULL;
-    ui->fg_color = NULL;
-    ui->bg_color = NULL;
+    ui->fg_color = 0;
+    ui->bg_color = 0;
     
     return(ui);
 }
index c4b8f65d3c3384f7e2bec67dc52b4486360a3575..b9d8f171dff0e08ec34b4da27d2e8a4f1304bb46 100644 (file)
@@ -689,7 +689,7 @@ init_glyph_elm(
 )
 {
     AB_OBJ             *obj = (AB_OBJ *)client_data;
-    Pixmap             image = NULL;   /* gotta set to NULL!!! */
+    Pixmap             image = 0;
 
     /*
      * Object glyph
@@ -1882,12 +1882,12 @@ get_toplevel_drawarea(
     BrowserUiObj       ui;
 
     if (!v)
-       return (NULL);
+       return 0;
 
     ui = (BrowserUiObj)v->ui_handle;
 
     if (!ui)
-       return (NULL);
+       return 0;
 
     instance = (DtbBrwsMainwindowInfo)ui->ip;
 
@@ -1904,12 +1904,12 @@ get_detailed_drawarea(
     BrowserUiObj       ui;
 
     if (!v)
-       return (NULL);
+       return 0;
 
     ui = (BrowserUiObj)v->ui_handle;
 
     if (!ui)
-       return (NULL);
+       return 0;
 
     instance = (DtbBrwsMainwindowInfo)(ui->ip);
 
@@ -1926,12 +1926,12 @@ get_proj_drawarea(
     BrowserUiObj       ui;
 
     if (!v)
-       return (NULL);
+       return 0;
 
     ui = (BrowserUiObj)v->ui_handle;
 
     if (!ui)
-       return (NULL);
+       return 0;
 
     proj_d = (DtbProjProjMainInfo)ui->ip;
 
index a653e3dbd219a8743f76d5030b16bf4aaa441bc5..104feee16e238e01aa1d84be65f17f818c57f188 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 89442cce6e52b4c9c90fd3940a5a0081ae424fbd..6180702532bc4cc870b273cb8df2bca67e2981bd 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 198a554bb1e7d4c811f27bd87b8c7ec4584aec6b..7a562886b4dcc2467e1523f6f0c0be0e5e98034e 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -240,7 +241,7 @@ cgenP_cancel_envCB(
     DtbCgenEnvDialogInfo        env_dlg = (DtbCgenEnvDialogInfo)clientData;
     char buf[10];
 
-    sprintf(buf, "");
+    sprintf(buf, "%s", "");
     XmTextFieldSetString(env_dlg->name_textf, buf);
     XmTextSetString(env_dlg->textpane, buf);
     
index 4ed6bece0692b4fd49d268c4947955501753ee09..9c04e1341a1005144ba56f2f80efaa7a2fc0129e 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index c658b532a4beaf9f44c5dc312be41bd6b1e245ca..c87a9f1b72367775267f3ef1ed25f9a92150fcd2 100644 (file)
@@ -49,6 +49,7 @@
 #define _POSIX_SOURCE 1
 #endif
 
+#include <stdint.h>
 #include <sys/types.h>
 #include <unistd.h>
 #include <stdlib.h>
@@ -703,7 +704,7 @@ term_execute_command(CG_SUBCOMMAND cmd_code, STRING cmd, STRING argv[])
            int         putenv_var_size = 0;
 
            setpgid(0,0);               /* make process group leader */
-           write_to_status_pipe(CG_STATUS_STARTED, cmd_code, (void*)getpgrp());
+           write_to_status_pipe(CG_STATUS_STARTED, cmd_code, (void*)(intptr_t) getpgrp());
 
            for (i = 0; i < num_env_vars; ++i)
            {
@@ -833,7 +834,7 @@ term_execute_command(CG_SUBCOMMAND cmd_code, STRING cmd, STRING argv[])
 
            if (status_pipe_write >= 0)
            {
-               write_to_status_pipe(status_code, cmd_code, (void*)exit_code);
+               write_to_status_pipe(status_code, cmd_code, (void*)(intptr_t) exit_code);
                 util_fdclose(status_pipe_write);
            }
             subprocess_exit(exit_code);
@@ -1583,12 +1584,12 @@ pipe_data_ready_proc(
     switch (status_code)
     {
        case CG_STATUS_STARTED:
-           actual_process_pgid = (pid_t)status_data;
+           actual_process_pgid = (pid_t)(intptr_t) status_data;
            /*util_dprintf(2,"rcv started: %ld\n", (long)actual_process_pgid);*/
        break;
 
        case CG_STATUS_EXITED:
-           exit_code = (int)status_data;
+           exit_code = (int)(intptr_t) status_data;
            actual_process_pgid = INVALID_PID;
            /*util_dprintf(2,"rcv exit(%d)\n", exit_code);*/
            if (aborted)
@@ -1607,7 +1608,7 @@ pipe_data_ready_proc(
        break;
 
        case CG_STATUS_SIGNALLED:
-           kill_signal = (int)status_data;
+           kill_signal = (int)(intptr_t) status_data;
            /*util_dprintf(2,"rcv signalled(%d)\n", kill_signal);*/
            actual_process_pgid = INVALID_PID;
            goto_ready_state();
index 46f535b2157663b7ff8835799fb5b0e4e4e66c7f..da96cf971090bc44b3bae49b76979a57588ab400 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 3d495be54772372357a22c70b53d6ddd21c0f163..d2d08e02c6de2708d16f97b6907ede8d70035bfd 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 666eb124b5c342c50fcaac14aa5e6c189b2fd966..43f0e0af36a7fc0821b4038cda2e139fa8252152 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 6dca2b17e88cb4774b6f3451b96a73cd84b40f06..104d25cf0c3b689eec9167d0af76752de23fddbc 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index e1b82e6173785b61f1e33954e94e8c0184a91d92..5a62c784845a13543d08bbef59cca7fcd563e1a1 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index beebd4087e7a22616fe5c541ee668ddf5f484a45..f53c60697272904a3d294f78a28fae40f86cbba1 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 7918ee5e67109d247fa34b83d2898bf412e95b26..ef78e75d95c8ee196240923715092be69ebf79a3 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index dacb3ebe305663c50843dc424af9504db03098d2..ee53ba9a5e5e878f9532ae0d1531e2e1423cc0b3 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -832,7 +833,7 @@ dnd_fetch_attrs(
        obj_get_drag_cursor_mask(obj), False);
     if (dragOps != 0)
        prop_radiobox_set_value(&(dds->drag_types_radiobox),
-               (XtPointer)dragType, False);
+               (XtPointer)(uintptr_t) dragType, False);
     
     prop_checkbox_set_value(&(dds->drop_ops_checkbox),
        ABDndOpCopy, ((dropOps & ABDndOpCopy) != 0), False);
index b2ad4b179b38af96483bedb120be32b060a5ade7..d341cb3a7a035ab7c37cd8e105aa170388ad052d 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 638a18701f289e56667be8f6d5af6092afd7fc61..9dd5af819797dccf809fcef59ab86d48333ff01c 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <unistd.h>
 #include <stdlib.h>
 #include <stdio.h>
@@ -1068,8 +1069,8 @@ import_change_modeCB(
 {
     XmToggleButtonCallbackStruct *state =
                 (XmToggleButtonCallbackStruct *)callData;
-    int                        ImportMode = (int) clientData;
-    ChooserInfo                info = NULL;
+    int                        ImportMode = (int)(intptr_t) clientData;
+    ChooserInfo                info = 0;
 
     if (state->set)
     {
@@ -1098,7 +1099,7 @@ import_formatCB(
 {
     XmToggleButtonCallbackStruct *state =
                 (XmToggleButtonCallbackStruct *)callData;
-    int                ImportFormat = (int) clientData;
+    int                ImportFormat = (int)(intptr_t) clientData;
     ChooserInfo        info = NULL;
     Widget             method_rbox = NULL;
 
@@ -1231,7 +1232,7 @@ main(int argc, char **argv)
                        layout_menu = (Widget) NULL;
     ABInitProcInfo      init_proc_info = NULL;
     int                        status = 0;
-    Pixmap             xpm_pixmap = NULL;
+    Pixmap             xpm_pixmap = 0;
     int                        num_mouse_buttons = 0;
 
 #ifdef DEBUG   /* performance testing */
@@ -1569,18 +1570,18 @@ main(int argc, char **argv)
 
     /* Register Menu Palette Obj */
     pal_register_item_info(NULL, ab_menu_palitem, (int)AB_NO_SUBTYPE,
-               NULL, NULL);
+               NULL, 0);
 
     /* Register Group Palette Obj */
     pal_register_item_info(NULL, ab_group_palitem, (int)AB_CONT_GROUP,
-               "Group", NULL);
+               "Group", 0);
 
     /* Register Paned Window Palette Obj */
     pal_register_item_info(NULL, ab_panedwin_palitem, (int)AB_CONT_PANED,
-               NULL, NULL);
+               NULL, 0);
 
     pal_register_item_info(NULL, ab_button_palitem, (int)AB_BUT_DRAWN,
-               "Drawn Button", NULL);
+               "Drawn Button", 0);
 
     /* Register All Editable objects which are not Palette Items */
     pal_register_editable_obj(AB_TYPE_PROJECT, (int)AB_NO_SUBTYPE,
index afaf6b3e53e03882bbe7b9fe86a3df8b653ac1e0..66a0abfee4473c8822b2d4c06b1d1502ad79eaa8 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 6933cbc086a0d22812adb90ee390079003f454ea..ffccc55c59fca3878471f991a3e29cb9959e3ce2 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 361c88d8d8a7c7eb9ae0bc53b4278629af2e5897..cab1f1c524dc07d9be37bdfe23985924f2961057 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -102,7 +103,7 @@ typedef struct HELP_OBJ_TYPE_INFO_REC {
        int             subtype;
 } HelpObjTypeInfoRec;
 static HelpObjTypeInfoRec HelpObjTypeInfo = {
-       ((AB_OBJECT_TYPE)NULL), ((int) NULL),
+       ((AB_OBJECT_TYPE)NULL), 0,
 };
 
 typedef struct HELP_EDITOR_SETTINGS {
@@ -897,8 +898,8 @@ help_dispatchCB(Widget widget, XtPointer clientData, XtPointer callData)
     ** Checking the status of the more-help info also lets us decide whether
     ** the "More..." button should be enabled on the dialog.
     */
-    if( help_volume     ==0 || *(help_volume) == NULL ||
-       help_location   ==0 || *(help_location)== NULL){
+    if( help_volume     ==0 || *(help_volume) == 0 ||
+       help_location   ==0 || *(help_location)== 0){
                buffer[0] = '\0';
     }
     else {
@@ -1373,7 +1374,7 @@ help_back_hdlr(Widget widget, XtPointer clientData, XtPointer callData)
     ** Parse the combined volume/locationID string.  Disable the "More..."
     ** button if there isn't any help info, and enable it if there is.
     */
-    if( buffer == 0 || (*buffer == NULL) ||
+    if( buffer == 0 || (*buffer == 0) ||
        (cp=strrchr(buffer,'/')) == (char *)NULL) {
                XtSetSensitive(more_button,False);
     }
index 0bab4a5fab4a3f8eced0dfd21b38d4cef06ffb29..60f9084c32f842f28596cb3a6a45a3331dfbbe06 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index b8223b62615a9ec3a198f46d28d2b3d5492a5896..7bed5ad049b2af8413de910c4d4454c0a2173ed7 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 3173fa80805a9dfb9b68870e20cf6c0262cd535b..b5c4d7b0527657075f1d44cfa1f6d057239f5fc5 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index de36927b4eec4c24159abd61ff6a42ffaf053261..6c5e00eb32be53a766ac4d89d2ab6828eec192da 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index af70b9fbb0f6d05be0a52c0c7f3f0a2cdd958f6f..868a24fe00e3848a7a4b8364b7b0f1a1fd44e65d 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index c3501bc1bc2b71496d00a7289ac8260dfb63a0f9..ae7a989f8cb73bc7f4f4939284a50b0129dc6ebe 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -877,7 +878,7 @@ typeCB(
            }
 
            /* Set the default button to be Action1 */
-           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != AB_DEFAULT_BTN_ACTION1)       
+           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != (XtPointer) AB_DEFAULT_BTN_ACTION1)   
            {
                prop_options_set_value(&(mes->default_btn), 
                                (XtPointer)AB_DEFAULT_BTN_ACTION1, True);
@@ -928,7 +929,7 @@ typeCB(
            }
 
             /* Set the default button to be Cancel */ 
-           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != AB_DEFAULT_BTN_CANCEL)        
+           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != (XtPointer) AB_DEFAULT_BTN_CANCEL)    
            {
                prop_options_set_value(&(mes->default_btn), 
                                 (XtPointer)AB_DEFAULT_BTN_CANCEL, True);
@@ -979,7 +980,7 @@ typeCB(
            }
 
             /* Set the default button to be Action2 */ 
-           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != AB_DEFAULT_BTN_ACTION2)       
+           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != (XtPointer) AB_DEFAULT_BTN_ACTION2)   
            {
                prop_options_set_value(&(mes->default_btn), 
                                 (XtPointer)AB_DEFAULT_BTN_ACTION2, True);
@@ -1031,7 +1032,7 @@ typeCB(
            }
 
             /* Set the default button to be Action1 */ 
-           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != AB_DEFAULT_BTN_ACTION1)       
+           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != (XtPointer) AB_DEFAULT_BTN_ACTION1)   
            {
                prop_options_set_value(&(mes->default_btn), 
                                 (XtPointer)AB_DEFAULT_BTN_ACTION1, True);
@@ -1079,7 +1080,7 @@ typeCB(
            }
 
             /* Set the default button to be Action1 */ 
-           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != AB_DEFAULT_BTN_ACTION1)       
+           if ((XtPointer)prop_options_get_value(&(mes->default_btn)) != (XtPointer) AB_DEFAULT_BTN_ACTION1)   
            {
                prop_options_set_value(&(mes->default_btn), 
                                 (XtPointer)AB_DEFAULT_BTN_ACTION1, True);
index 9a37c4ffc811ae37682886443b053faf8877aa3a..2eaa3703cbfccf7ec6500b160a237764662701b1 100644 (file)
@@ -179,7 +179,7 @@ pal_register_item_info(
                newsub[i] = sub[i];
 
            newsub[i].subtype = subtype;
-           newsub[i].pixmap  = NULL;
+           newsub[i].pixmap  = 0;
            newsub[i].subname = XtNewString(subname);
            XtFree((char *)(palitem->subinfo));
            palitem->subinfo = newsub;
@@ -297,7 +297,7 @@ pal_get_item_pixmap(
     }
 
     *p_width  = *p_height = 0;
-    return NULL;
+    return 0;
 
 }
 STRING
index 7a6fad2e3a631c567cb7ad70a415db7506a89182..6b9a9a4c40f9a01abec337f773e48f9ce5926807 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_combobox.c - Implements Palette ComboBox object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/obj_notify.h>
@@ -527,7 +528,7 @@ combo_box_prop_load(
 
        /* Load Read Only */
        prop_radiobox_set_value(&(pcs->combobox_type),
-                               (XtPointer)obj_get_read_only(obj), False);
+                               (XtPointer)(intptr_t) obj_get_read_only(obj), False);
 
        /* Load Initial State */
        prop_checkbox_set_value(&(pcs->init_state), AB_STATE_VISIBLE,
index ad60a6df4022298f9df0f211f567e4fbacffdb84..3ebc3a8ac19cc6637c57079a9db43737e6e8f7d8 100644 (file)
@@ -457,7 +457,7 @@ initiate_drag(
 
     static unsigned int          max_c_width = 0; /* The maximum cursor size */
     static unsigned int          max_c_height = 0;
-    static Pixmap        item_pixmap = NULL;/* pixmap for cursor */
+    static Pixmap        item_pixmap = 0;/* pixmap for cursor */
     static GC            p_gc = NULL;       /* GC used for pixmap creation */
     char                 *server_vendor = NULL;
     PalItemInfo          *palitem;            /* palette obj */
index d6f3834de87e29dc923f182dae6920ab91a362ff..fea7c6ee61abeb6c3c1e5a3db4cd71ba51fd5f02 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_custdlg.c - Implements Palette CustomDialog object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/util.h>
@@ -300,7 +301,7 @@ custdlg_prop_init(
         /* Window Parent */
         n = 0;
         item[n] = cgen->winparent_opmenu_items.None_item;
-        item_val[n] = NULL; n++;
+        item_val[n] = 0; n++;
         prop_obj_options_init(&(pcs->win_parent), cgen->winparent_opmenu_label,
                 cgen->winparent_opmenu, cgen->winparent_opmenu_menu,
                 n, item, (XtPointer*)item_val,
@@ -335,7 +336,7 @@ custdlg_prop_init(
        /* Default Button */
         n = 0;
         item[n] = cgen->defaultb_opmenu_items.None_item;
-        item_val[n] = NULL; n++;
+        item_val[n] = 0; n++;
        prop_obj_options_init(&(pcs->default_but), cgen->defaultb_opmenu_label,
                cgen->defaultb_opmenu, cgen->defaultb_opmenu_menu,
                n, item, (XtPointer*)item_val,
@@ -345,7 +346,7 @@ custdlg_prop_init(
        /* Help Button */
         n = 0;
         item[n] = cgen->helpb_opmenu_items.None_item;
-        item_val[n] = NULL; n++;
+        item_val[n] = 0; n++;
        prop_obj_options_init(&(pcs->help_but), cgen->helpb_opmenu_label,
                cgen->helpb_opmenu, cgen->helpb_opmenu_menu,
                n, item, (XtPointer*)item_val,
@@ -506,7 +507,7 @@ custdlg_prop_load(
 
        /* Load Resize Mode */
        prop_radiobox_set_value(&(pcs->resize_mode),
-                                (XtPointer)obj_get_resizable(obj), False);
+                                (XtPointer)(intptr_t) obj_get_resizable(obj), False);
 
        /* Load Window Areas */
        area = objxm_comp_custdlg_get_area(obj, AB_CONT_BUTTON_PANEL);
@@ -867,10 +868,10 @@ custdlg_create_buttons(
         obj_set_is_initially_visible(bobj, True);
         obj_set_is_initially_active(bobj, True);
         startpos = endpos + 10;
-        obj_set_attachment(bobj, AB_CP_WEST, AB_ATTACH_GRIDLINE, (void*)startpos, 0);
+        obj_set_attachment(bobj, AB_CP_WEST, AB_ATTACH_GRIDLINE, (void*)(intptr_t) startpos, 0);
         endpos = startpos + 20;
-        obj_set_attachment(bobj, AB_CP_EAST, AB_ATTACH_GRIDLINE, (void*)endpos, 0);
-       obj_set_attachment(bobj, AB_CP_NORTH, AB_ATTACH_POINT, (void*)0, 5);
+        obj_set_attachment(bobj, AB_CP_EAST, AB_ATTACH_GRIDLINE, (void*)(intptr_t) endpos, 0);
+       obj_set_attachment(bobj, AB_CP_NORTH, AB_ATTACH_POINT, NULL, 5);
     }
 
 }
index ff8723c7f2185b81d61fab93c143d231ac39d56c..05e48d365682b55c958c8716b0459d8cd2381ef3 100644 (file)
@@ -45,6 +45,7 @@
  * pal_group.c - Implements Group object functionality
  */
 
+#include <stdint.h>
 #include <stdlib.h>
 #include <stdio.h>
 #include <X11/Xlib.h>
@@ -1943,7 +1944,7 @@ group_align_hcenters(
                int             height = abobj_get_actual_height(child);
 
                attach.type = AB_ATTACH_GRIDLINE;
-               attach.value = (void *)gridline;
+               attach.value = (void *)(intptr_t) gridline;
                attach.offset = -(height/2);
            }
 
@@ -2360,7 +2361,7 @@ group_align_vcenters(
                int             width = abobj_get_actual_width(child);
 
                attach.type = AB_ATTACH_GRIDLINE;
-               attach.value = (void *)gridline;
+               attach.value = (void *)(intptr_t) gridline;
                attach.offset = -(width/2);
            }
 
index f58560aece63cc64f5fabe454323e63e5dd10432..29e663b460a4911bbce1f1d4077b12ac9e7a647c 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_list.c - Implements Palette List object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/obj_notify.h>
@@ -706,7 +707,7 @@ list_prop_apply(
     }
     if (prop_changed(pls->hgt.changebar))
     {
-       metric = (int)prop_options_get_value(&(pls->hgt_metric));
+       metric = (int)(intptr_t) prop_options_get_value(&(pls->hgt_metric));
        new_h = prop_geomfield_get_value(&(pls->hgt), GEOM_HEIGHT);
 
         abobj_set_num_rows(pls->current_obj,
index b92cfd614c7f7683262caa18ea4fd944d594b2b4..83f35f0bedce1515d3f0fccbf1df51adaffa89af 100644 (file)
@@ -43,6 +43,7 @@
 /*
  * pal_mainwin.c - Implements Palette Main Window object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/ab.h>
@@ -455,7 +456,7 @@ mainwin_prop_load(
 
        /* Load Resize Mode */
        prop_radiobox_set_value(&(pms->resize_mode),
-                                (XtPointer)obj_get_resizable(obj), False);
+                                (XtPointer)(intptr_t) obj_get_resizable(obj), False);
 
        /* Load Icon Filename */
        prop_field_set_value(&(pms->icon), obj_get_icon(obj), False);
index 51fa46add2279b26ed304a9da8c1d12525dda0d8..8b3551d6ec84aa132a07034bd188423636f402c8 100644 (file)
@@ -44,6 +44,7 @@
  * pal_menu.c - Implements Palette Menu object functionality
  *             NOTE: menu not actually ON the main palette
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/obj_notify.h>
@@ -577,7 +578,7 @@ menu_prop_load(
     {
        /* Load Tearoff */
        prop_radiobox_set_value(&(pms->tearoff),
-               (XtPointer)(obj->info.menu.tear_off), False);
+               (XtPointer)(intptr_t) (obj->info.menu.tear_off), False);
 
        /* Load Color */
        prop_colorfield_set_value(&(pms->bg_color), obj_get_bg_color(obj), False);
index 2b551a3e24ee8c2a7c7722bedf00f2541bceb02d..d18d133ad8f0ae0d9b5cc8b54c3dd84041fbf955 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_scale.c - Implements Palette Scale/Gauge object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/ab.h>
@@ -531,7 +532,7 @@ scale_prop_load(
 
        /* Load Scale Type */
        prop_radiobox_set_value(&(pss->scale_type),
-                                (XtPointer)obj_get_read_only(obj), False);
+                                (XtPointer)(intptr_t) obj_get_read_only(obj), False);
 
        /* Load Orientation */
        orient = obj_get_orientation(obj);
index 907368e9a6dba03bee438ba92839c0dd9d0ef046..32789ca273a429f43055b2578317585e4d9a9efb 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_termp.c - Implements Palette TermPane object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <Dt/TermPrim.h>
@@ -545,7 +546,7 @@ termp_prop_apply(
     }
     if (prop_changed(pts->size.changebar))
     {
-       metric = (int)prop_options_get_value(&(pts->size_metric));
+       metric = (int)(intptr_t) prop_options_get_value(&(pts->size_metric));
        new_w = prop_geomfield_get_value(&(pts->size), GEOM_WIDTH);
        new_h = prop_geomfield_get_value(&(pts->size), GEOM_HEIGHT);
 
index 2f605a84aa0e6244e54405c0e715bb9122508b44..7570550cffdf3e50b4d2353484f8c37f4c5c108d 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_textf.c - Implements Palette TextField object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/pal.h>
@@ -466,7 +467,7 @@ textf_prop_load(
                                obj->label_type, obj_get_label(obj), AB_LINE_UNDEF);
        /* Load Operation */
        prop_radiobox_set_value(&(pts->op),
-                                (XtPointer)obj_get_read_only(obj), False);
+                                (XtPointer)(intptr_t) obj_get_read_only(obj), False);
 
        /* Load Maximum Chars */
        prop_field_set_numeric_value(&(pts->max_chars), obj_get_max_length(obj), False);
@@ -580,7 +581,7 @@ textf_prop_apply(
     }
     if (prop_changed(pts->size.changebar))
     {
-       metric = (int)prop_options_get_value(&(pts->size_metric));
+       metric = (int)(intptr_t) prop_options_get_value(&(pts->size_metric));
        new_w = prop_geomfield_get_value(&(pts->size), GEOM_WIDTH);
 
         abobj_set_num_columns(pts->current_obj,
index de9afc8532a6fe5a9dafd2c4610349652d4babeb..bd73c9b23c45f71881d36d9e9b5c51965e53c024 100644 (file)
@@ -44,6 +44,7 @@
 /*
  * pal_textp.c - Implements Palette TextPane object functionality
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <ab_private/util.h>
@@ -488,7 +489,7 @@ textp_prop_load(
 
        /* Load Operation */
        prop_radiobox_set_value(&(pts->op),
-                                (XtPointer)obj_get_read_only(obj), False);
+                                (XtPointer)(intptr_t) obj_get_read_only(obj), False);
 
        /* Load Menu Name/Title */
        prop_menuname_set_value(&(pts->menuname), obj_get_menu_name(obj), False);
@@ -581,7 +582,7 @@ textp_prop_apply(
     }
     if (prop_changed(pts->size.changebar))
     {
-       metric = (int)prop_options_get_value(&(pts->size_metric));
+       metric = (int)(intptr_t) prop_options_get_value(&(pts->size_metric));
         new_w = prop_geomfield_get_value(&(pts->size), GEOM_WIDTH);
         new_h = prop_geomfield_get_value(&(pts->size), GEOM_HEIGHT);
 
index 8f40f0fad6bc3bdd74857cbb6fecca6d4ff58b81..004bc6e5d4efa051a1a6b55520ed36678d10d733 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
@@ -227,15 +228,15 @@ register_palette_info(
     {
         case AB_TYPE_BASE_WINDOW:
                 pal_register_item_info(palitem_w, ab_mainwin_palitem, 
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_BUTTON:
                 if (strcmp(subtypestr, "AB_BUT_PUSH") == 0)
                     pal_register_item_info(palitem_w, ab_button_palitem,
-                       (int)AB_BUT_PUSH, ab_button_palitem->name, NULL);
+                       (int)AB_BUT_PUSH, ab_button_palitem->name, 0);
                 else if (strcmp(subtypestr, "AB_BUT_MENU") == 0)
                     pal_register_item_info(palitem_w, ab_button_palitem,
-                       (int)AB_BUT_MENU, "Menu Button", NULL);
+                       (int)AB_BUT_MENU, "Menu Button", 0);
                 break;
         case AB_TYPE_COMBO_BOX:
         {
@@ -243,7 +244,7 @@ register_palette_info(
                 WidgetList  children = NULL;
  
                 pal_register_item_info(palitem_w, ab_combo_box_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
  
                 num_children = 0;
                 XtVaGetValues(palitem_w,
@@ -265,53 +266,53 @@ register_palette_info(
         case AB_TYPE_CONTAINER:
                 if (strcmp(subtypestr, "AB_CONT_RELATIVE") == 0)
                     pal_register_item_info(palitem_w, ab_cpanel_palitem,
-                       (int)AB_CONT_RELATIVE, ab_cpanel_palitem->name, NULL);
+                       (int)AB_CONT_RELATIVE, ab_cpanel_palitem->name, 0);
                 else if (strcmp(subtypestr, "AB_CONT_MENU_BAR") == 0)
                     pal_register_item_info(palitem_w, ab_menubar_palitem,
-                       (int)AB_CONT_MENU_BAR, ab_menubar_palitem->name, NULL);
+                       (int)AB_CONT_MENU_BAR, ab_menubar_palitem->name, 0);
                 break;
         case AB_TYPE_DIALOG:
                 pal_register_item_info(palitem_w, ab_custdlg_palitem,
-                       (int)AB_NO_SUBTYPE, ab_custdlg_palitem->name, NULL);
+                       (int)AB_NO_SUBTYPE, ab_custdlg_palitem->name, 0);
                 break;
         case AB_TYPE_LABEL:
                 pal_register_item_info(palitem_w, ab_label_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_TERM_PANE:
                 pal_register_item_info(palitem_w, ab_termp_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_TEXT_FIELD:
                 pal_register_item_info(palitem_w, ab_textf_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_TEXT_PANE:
                 pal_register_item_info(palitem_w, ab_textp_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_LIST:
                 pal_register_item_info(palitem_w, ab_list_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_CHOICE:
                 if (strcmp(subtypestr, "AB_CHOICE_EXCLUSIVE") == 0)
                     pal_register_item_info(palitem_w, ab_choice_palitem,
-                       (int)AB_CHOICE_EXCLUSIVE, "Radio Box", NULL);
+                       (int)AB_CHOICE_EXCLUSIVE, "Radio Box", 0);
                 else if (strcmp(subtypestr, "AB_CHOICE_OPTION_MENU") == 0)
                     pal_register_item_info(palitem_w, ab_choice_palitem,
-                       (int)AB_CHOICE_OPTION_MENU, "Option Menu", NULL);
+                       (int)AB_CHOICE_OPTION_MENU, "Option Menu", 0);
                 else     
                     pal_register_item_info(palitem_w, ab_choice_palitem,
-                       (int)AB_CHOICE_NONEXCLUSIVE, "Check Box", NULL);
+                       (int)AB_CHOICE_NONEXCLUSIVE, "Check Box", 0);
                 break;    
         case AB_TYPE_DRAWING_AREA:
                 pal_register_item_info(palitem_w, ab_drawp_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_SEPARATOR:
                 pal_register_item_info(palitem_w, ab_separator_palitem,
-                       (int)AB_NO_SUBTYPE, NULL, NULL);
+                       (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
         case AB_TYPE_SPIN_BOX:
         {
@@ -319,7 +320,7 @@ register_palette_info(
                 WidgetList  children = NULL;
  
                 pal_register_item_info(palitem_w, ab_spinbox_palitem,
-                        (int)AB_NO_SUBTYPE, NULL, NULL);
+                        (int)AB_NO_SUBTYPE, NULL, 0);
         
                 XtVaGetValues(palitem_w,
                         XtNnumChildren,    &num_children,
@@ -357,7 +358,7 @@ register_palette_info(
                 {
  
                     pal_register_item_info(palitem_w, ab_scale_palitem,
-                       (int)False, "Scale", NULL);
+                       (int)False, "Scale", 0);
                     /*
                      * Register sub-widgets of scale as well
                      */
@@ -371,7 +372,7 @@ register_palette_info(
                 else
                 {
                     pal_register_item_info(palitem_w, ab_scale_palitem,
-                       (int)True, "Gauge", NULL);
+                       (int)True, "Gauge", 0);
                     /*
                      * Register sub-widgets of gauge as well
                      */
@@ -386,7 +387,7 @@ register_palette_info(
         }
         case AB_TYPE_FILE_CHOOSER: 
                 pal_register_item_info(palitem_w, ab_fchooser_palitem,
-                        (int)AB_NO_SUBTYPE, NULL, NULL);
+                        (int)AB_NO_SUBTYPE, NULL, 0);
                 break;
     }
 }
index e756b41dc670bf746163b3edf3c043e6c50c187f..e5017d59a19640cb43da59ed95aeefda899c52b0 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 70257fe80a48b5f486a9b99a5a4e87d330be9976..567a920b79fd1b42fd0005b1de98a5546c80e181 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 84a4f64ee4bac018000b0591f422d350d4cfa5ba..a891453a50302d9c1ce20c9bf1a7ca1124d21ff3 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index a9cf0e4a6306475cbded0207fac27e401e6c5209..405f24a97f83f245874613945fd81be7d371360a 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index f8368e85e92f4260f9f1a97cd02de3e67351a677..718c7b0283bf5f05693f39c58576b3c603e5b0c8 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 034a432c87532ebc3ed63308e3f881608f32627d..3bc06b38ad8dea8f3140663039e64cf779b464e6 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index b5426487b451ef927b9ef0a820d5b7b5c6d3af60..4d980288996fe192bae1a77423d6bbefb455b7cf 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 871118d8a58b1e3bb86aa6657ed34cf6fd29c034..6f93879b074cb1f690ea3958e4025beb14e3a855 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index 5e60a1c1f6a8f02986cc0142741a1d77a1b1359f..2b04f3fa67d25334183ae9494cdaf21e69440fb7 100644 (file)
@@ -38,6 +38,7 @@
  *  ** DELETE THE GENERATED COMMENTS!                                 **
  */
 
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include "dtb_utils.h"
index dedf682eeb8fa20751ac78a41c429f72e181ff91..cc55c57da5c8c78bb0446d9e1d3344cd5e4476c5 100644 (file)
@@ -48,6 +48,7 @@
  *
  ***********************************************************************
  */
+#include <stdint.h>
 #include <stdio.h>
 #include <Xm/Xm.h>
 #include <Xm/MessageB.h>
@@ -361,7 +362,7 @@ destroyCB(
     XtPointer  call_data
 )
 {
-    int    yes = (int)client_data;
+    int    yes = (int)(intptr_t) client_data;
 
    /* REMIND: aim,1/29/94 - temp. fix for prompt dialog crashing */
     if (yes == 1)
index 9c5bbf16bbeb380751c0f67b15311e48bcc6600e..4738b382703f20ab7b07274706c79c934bf23861 100644 (file)
@@ -207,7 +207,7 @@ static UiObjPixmap  object_pixmaps[] =
 /*
  * Default pixmap
  */
-static Pixmap          default_pixmap = NULL;
+static Pixmap          default_pixmap = 0;
 static unsigned int    default_pixmap_width = 0;
 static unsigned int    default_pixmap_height = 0;
 
@@ -472,8 +472,8 @@ ui_set_label_glyph(
     STRING      fileName
 )
 {
-    Pixmap    labelPixmap            = NULL;
-    Pixmap    labelInsensitivePixmap = NULL;
+    Pixmap    labelPixmap            = 0;
+    Pixmap    labelInsensitivePixmap = 0;
     
     XtVaGetValues(widget,
        XmNlabelPixmap,            &labelPixmap,
@@ -797,14 +797,14 @@ ui_set_busy_cursor(
     BOOL       on
 )
 {
-    static Cursor  busy_cursor = NULL;
+    static Cursor  busy_cursor = 0;
     static Display *dpy        = NULL;
 
     if (on) /* Turn ON busy cursor */
     {
        dpy = XtDisplay(AB_toplevel);
 
-       if (busy_cursor == NULL)
+       if (busy_cursor == 0)
            busy_cursor = XCreateFontCursor(dpy, XC_watch);
 
         XDefineCursor(dpy, window, busy_cursor);
@@ -920,7 +920,7 @@ ui_get_obj_pixmap
     int                        i;
     AB_OBJECT_TYPE     type;
     int                        subtype;
-    Pixmap             p = NULL;
+    Pixmap             p = 0;
     BOOL               found = FALSE;
 
     if (!obj || !pixmap || !width || !height)
@@ -1164,7 +1164,7 @@ ui_sync_display_of_widget(Widget widget)
     syncData.last_expose_ticks = 0;
     syncData.timeout_ticks = 0;
     syncData.display = NULL;
-    syncData.window = NULL;
+    syncData.window = 0;
 #define last_expose_ticks (syncData.last_expose_ticks)
 #define synced (syncData.synced)
 #define timeout_ticks (syncData.timeout_ticks)
@@ -1351,7 +1351,7 @@ ui_initiate_rubberband(
         ButtonReleaseMask | ButtonMotionMask | PointerMotionMask,
         GrabModeAsync, GrabModeAsync,  
        confine_to_window ? XtWindow(widget) : None,
-            NULL, CurrentTime) == GrabSuccess)
+            0, CurrentTime) == GrabSuccess)
     {
        rband_in_progress = True;
         rubberband_func = rb_func;
index bc1facf38008232f448168ff31454a36ac032ca4..d5a6333a892eea543eaad78d81257fdbc83a84bc 100644 (file)
@@ -49,6 +49,7 @@
 
 #include <assert.h>            /* assert() */
 #include <stdio.h>             /* FILE*, BUFSIZ */
+#include <stdint.h>
 #include <sys/param.h>         /* MAXPATHLEN, ... */
 #include <nl_types.h>
 #include <X11/Intrinsic.h>
@@ -174,7 +175,7 @@ typedef CGenAnyData CGenData;
 
 #define mfobj_set_module_data(_obj,_data) \
        ( mfobj_set_flags(_obj, CGenFlagDataIsModule), \
-         ((int)(mfobj_data(_obj)->info.module = (_data))) \
+         ((int)(intptr_t)(mfobj_data(_obj)->info.module = (_data))) \
        )
 
 #define mfobj_get_module_data(obj) \
index 23d09fbde5a856376e30a14ac2792a753d21cbc0..96f12534b56e461a7ba68030219ef4d130b0d7fc 100644 (file)
@@ -44,6 +44,7 @@
  */
 
 #include <stdio.h>
+#include <stdint.h>
 #include <assert.h>
 #include <Xm/Xm.h>
 #include <Xm/XmStrDefs.h>
@@ -213,10 +214,10 @@ abmfP_args_init(void)
 /* INT VALUES */
 #define dump_int_resource(inst,name,value) \
        (wroteResource = TRUE, \
-        fprintf(fp,"%s.%s:\t%d\n", inst, name, value))
+        fprintf(fp,"%s.%s:\t%d\n", inst, name, (int)(intptr_t)value))
 
 #define write_int_resource(name,value) \
-       (wroteResource = TRUE, abio_printf(fp,"%s, %d", name, (int)(value)))
+       (wroteResource = TRUE, abio_printf(fp,"%s, %d", name, (int)(intptr_t)(value)))
 
 /* STRING values */
 #define dump_str_resource(inst,name,value) \
index 3c4f9624f2aae98c42acf0adabb4a044b74feb83..060943ac87b1160e9815f069d708dc5b623a7b40 100644 (file)
@@ -644,53 +644,53 @@ write_define_display_var(GenCodeInfo genCodeInfo)
 
 
 /*
- * var: Drawable drawable = NULL;
+ * var: Drawable drawable = 0;
  */
 static int
 write_define_drawable_var(GenCodeInfo genCodeInfo)
 {
     make_istr_var_name(varDrawable, "drawable");
        write_define_var(genCodeInfo, &abmfP_drawable_var(genCodeInfo),
-               "Drawable", varDrawable, abmfP_str_null);
+               "Drawable", varDrawable, abmfP_str_zero);
     return 0;
 }
 
 
 /*
- * var: Pixmap icon_pixmap = NULL;
+ * var: Pixmap icon_pixmap = 0;
  */
 static int
 write_define_icon_pixmap_var(GenCodeInfo genCodeInfo)
 {
     make_istr_var_name(varIconPixmap, "icon_pixmap");
        write_define_var(genCodeInfo, &abmfP_icon_pixmap_var(genCodeInfo),
-               "Pixmap", varIconPixmap, abmfP_str_null);
+               "Pixmap", varIconPixmap, abmfP_str_zero);
     return 0;
 }
 
 
 /*
- * var: Pixmap icon_mask_pixmap = NULL;
+ * var: Pixmap icon_mask_pixmap = 0;
  */
 static int
 write_define_icon_mask_pixmap_var(GenCodeInfo genCodeInfo)
 {
     make_istr_var_name(varIconPixmap, "icon_mask_pixmap");
        write_define_var(genCodeInfo, &abmfP_icon_mask_pixmap_var(genCodeInfo),
-               "Pixmap", varIconPixmap, abmfP_str_null);
+               "Pixmap", varIconPixmap, abmfP_str_zero);
     return 0;
 }
 
 
 /*
- * var: Pixmap label_pixmap = NULL;
+ * var: Pixmap label_pixmap = 0;
  */
 static int
 write_define_label_pixmap_var(GenCodeInfo genCodeInfo)
 {
     make_istr_var_name(varLabelPixmap, "label_pixmap");
        write_define_var(genCodeInfo, &abmfP_label_pixmap_var(genCodeInfo),
-               "Pixmap", varLabelPixmap, abmfP_str_null);
+               "Pixmap", varLabelPixmap, abmfP_str_zero);
     return 0;
 }
 
index fbddd05854522c084c3b51ba83cbfb4722f3b121..4a5fc770a1ffb961dcad9580071f78564eba0ce2 100644 (file)
@@ -190,7 +190,7 @@ write_assign_local_vars_for_icon(GenCodeInfo genCodeInfo, ABObj obj)
         else
        */
         {
-           sprintf(parentName, abmfP_get_widget_parent_name(genCodeInfo, obj));
+           sprintf(parentName, "%s", abmfP_get_widget_parent_name(genCodeInfo, obj));
        }
     }
 
index 2be03cf3fb237fd127329540f55a6351e3c3b895..54d8e4c847f954c0dd5f3a62caec79b0778dd0e0 100644 (file)
@@ -264,11 +264,11 @@ static LibFuncRec abmfP_lrc_set_label_pixmaps =
     "     * Set the approriate resources.\n"
     "     */\n"
     "    XtVaSetValues(widget, XmNlabelType,   XmPIXMAP, NULL);\n"
-    "    if (labelPixmap != NULL)\n"
+    "    if (labelPixmap != 0)\n"
     "    {\n"
     "  XtVaSetValues(widget, XmNlabelPixmap, labelPixmap, NULL);\n"
     "    }\n"
-    "    if (labelInsensitivePixmap != NULL)\n"
+    "    if (labelInsensitivePixmap != 0)\n"
     "    {\n"
     "  XtVaSetValues(widget, XmNlabelInsensitivePixmap, \n"
     "                          labelInsensitivePixmap, NULL);\n"
@@ -952,8 +952,8 @@ static LibFuncRec abmfP_lrc_help_dispatch =
     "    ** Checking the status of the more-help info also lets us decide whether\n"
     "    ** the \"More...\" button should be enabled on the dialog.\n"
     "    */\n"
-    "    if( help_data->help_volume     ==0 || *(help_data->help_volume) == NULL ||\n"
-    "  help_data->help_locationID ==0 || *(help_data->help_locationID)== NULL){\n"
+    "    if( help_data->help_volume     ==0 || *(help_data->help_volume) == 0 ||\n"
+    "  help_data->help_locationID ==0 || *(help_data->help_locationID)== 0){\n"
     "          buffer[0] = '\\0';\n"
     "    }\n"
     "    else {\n"
@@ -1075,7 +1075,7 @@ static LibFuncRec abmfP_lrc_help_back_hdlr =
     "    ** Parse the combined volume/locationID string.  Disable the \"More...\"\n"
     "    ** button if there isn't any help info, and enable it if there is.\n"
     "    */\n"
-    "    if( buffer == 0 || (*buffer == NULL) ||\n"
+    "    if( buffer == 0 || (*buffer == 0) ||\n"
     "  (cp=strrchr(buffer,'/')) == (char *)NULL) {\n"
     "          XtSetSensitive(more_button,False);\n"
     "    }\n"
index 1c701b62457126149d552145cfa5d7a0a8077955..c1b662e55088afd93d41d16e7d848fbe5beabd9b 100644 (file)
@@ -1119,8 +1119,8 @@ dtb_help_dispatch(
     ** Checking the status of the more-help info also lets us decide whether
     ** the "More..." button should be enabled on the dialog.
     */
-    if( help_data->help_volume     ==0 || *(help_data->help_volume) == NULL ||
-       help_data->help_locationID ==0 || *(help_data->help_locationID)== NULL){
+    if( help_data->help_volume     ==0 || *(help_data->help_volume) == 0 ||
+       help_data->help_locationID ==0 || *(help_data->help_locationID)== 0){
                buffer[0] = '\0';
     }
     else {
index 0470543371968b0cb1e4b805d54a19a19cd9994d..ef66418ff3b26805918a4ebe8768b59d58d06cb1 100644 (file)
@@ -950,6 +950,7 @@ abmfP_write_stubs_c_file(
      * Write includes.
      */
     strcpy(moduleHeaderFileName, abmfP_get_ui_header_file_name(module));
+    abmfP_write_c_system_include(genCodeInfo, "stdint.h");
     abmfP_write_c_system_include(genCodeInfo, "stdio.h");
     abmfP_write_c_system_include(genCodeInfo, "Xm/Xm.h");
     abmfP_write_c_local_include(genCodeInfo, 
index 834c0315a9217f81fe823c14456573e67f409f97..0accd81194dbc981d3d03f92468997e67be7799a 100644 (file)
@@ -74,20 +74,20 @@ static int write_func_def_params(
 **                                                                      **
 **************************************************************************/
 
-extern STRING  abmfP_str_bool= "Boolean";
-extern STRING  abmfP_str_int= "int";
-extern STRING  abmfP_str_string= "String";
-extern STRING  abmfP_str_void= "void";
-extern STRING  abmfP_str_widget = "Widget";
-extern STRING  abmfP_str_xtpointer = "XtPointer";
-extern STRING  abmfP_str_tt_msg= "Tt_message";
-extern STRING  abmfP_str_voidpointer= "void *";
-extern STRING  abmfP_str_intpointer= "int *";
-extern STRING  abmfP_str_argvpointer= "char ***";
-
-extern STRING  abmfP_str_empty = "";
-extern STRING  abmfP_str_null = "NULL";
-extern STRING  abmfP_str_zero = "0";
+STRING abmfP_str_bool= "Boolean";
+STRING abmfP_str_int= "int";
+STRING abmfP_str_string= "String";
+STRING abmfP_str_void= "void";
+STRING abmfP_str_widget = "Widget";
+STRING abmfP_str_xtpointer = "XtPointer";
+STRING abmfP_str_tt_msg= "Tt_message";
+STRING abmfP_str_voidpointer= "void *";
+STRING abmfP_str_intpointer= "int *";
+STRING abmfP_str_argvpointer= "char ***";
+
+STRING abmfP_str_empty = "";
+STRING abmfP_str_null = "NULL";
+STRING abmfP_str_zero = "0";
 
 
 /*************************************************************************
index bed2474a4b7b6b0061d7f0ca0b4ea83d794d5695..c14616f6b5768ae1b8458d1f0d7da5c8c56cf9cf 100644 (file)
@@ -43,6 +43,7 @@
  * This file contains the implementation of the uil load
  * component
  */
+#include <stdint.h>
 #include <stdlib.h>
 #include <ctype.h>
 #include <string.h>
@@ -911,7 +912,7 @@ resource_value_for_uil_arg(
        ret_val = (XtPointer)uil_child;
 
 
-       abobj_ref = (ABObj)uil_child->header.user_data;
+       abobj_ref = (ABObj)(uintptr_t) uil_child->header.user_data;
 
        if (abobj_ref == NULL)
        {
@@ -1425,7 +1426,7 @@ object_for_widget(
        obj_get_attach_value(rr->obj, rr->dir);
     if (field_widget == NULL)
        return;
-    obj_ref = (ABObj)field_widget->header.user_data;
+    obj_ref = (ABObj)(uintptr_t) field_widget->header.user_data;
     obj_set_attach_value(rr->obj, rr->dir, obj_ref);
     XtFree((char *)rr);
 }
index 1298b9b1b01e0ab2eb624200f8288a46c1f2be1e..db19e1abe01704426c9221f3e96e6cca6f5ba9b0 100644 (file)
@@ -547,7 +547,7 @@ output_ui_arg(FILE *fp, ABObj obj, Arg *arg)
            break;
        case AB_ARG_STRING:
            indent(fp,DBLSP); 
-           fprintf(fp,"XmN%s = \"%s\" ;\n",arg->name,arg->value);
+           fprintf(fp,"XmN%s = \"%s\" ;\n",arg->name, (char *) arg->value);
            break;
        case AB_ARG_BOOLEAN:
            /* REMIND: handle item obj's XmNset resource for an array */
@@ -568,7 +568,7 @@ output_ui_arg(FILE *fp, ABObj obj, Arg *arg)
            break;
        case AB_ARG_FONT:
            indent(fp,DBLSP);
-           fprintf(fp,"XmN%s = \"%s\" ;\n",arg->name,arg->value);
+           fprintf(fp,"XmN%s = \"%s\" ;\n",arg->name, (char *) arg->value);
            break;
        case AB_ARG_LITERAL:    /* istring, but not quoted in output */
            indent(fp,DBLSP);
index b21be9dfb390b1127786b5035e858937ce6818f2..1c1a6e7b98dedc1613e2fa42eaa8b07f774697f8 100644 (file)
@@ -42,6 +42,7 @@
 /*
  * This file contains the mapping between uil resources and ABObj attributes
  */
+#include <stdint.h>
 #include <stdlib.h>
 #include <ctype.h>
 #include <stdio.h>
@@ -3950,11 +3951,11 @@ val_proc_debug(
     {
       case AB_ARG_STRING:
       case AB_ARG_LITERAL:
-         fprintf(stderr,", value = %s\n",res_value); break;
+         fprintf(stderr,", value = %s\n", (char*) res_value); break;
       case AB_ARG_INT:
-         fprintf(stderr,", value = %d\n",res_value); break;
+         fprintf(stderr,", value = %d\n", (int)(intptr_t) res_value); break;
       case AB_ARG_FLOAT:
-         fprintf(stderr,", value = %g\n",res_value); break;
+         fprintf(stderr,", value = %g\n", (double)(uintptr_t) res_value); break;
       case AB_ARG_BOOLEAN:
          if(res_value) fprintf(stderr,", value = TRUE\n");
          else          fprintf(stderr,", value = FALSE\n");
index accdc454320ba37fa4abea214dbabeec2bb3e01b..4db9d99b66d30072983fadf7fd262a5fed369c0b 100644 (file)
@@ -46,6 +46,7 @@
 #include <ctype.h>
 #include <stdio.h>
 #include <string.h>
+#include <stdint.h>
 
 #include <ab_private/UilDef.h>
 #include <uil/UilDBDef.h>
@@ -340,10 +341,10 @@ print_uil_symbol(
            int i;
 
            printf("%lx  unknown type: %d  size: %d  byte: 0x%x\n",
-                         az_symbol_entry,
+                         (unsigned long) az_symbol_entry,
                          az_symbol_entry->header.b_tag,
                          az_symbol_entry->header.w_node_size,
-                         az_symbol_entry->header.b_type);
+                         (unsigned) az_symbol_entry->header.b_type);
 
            l_array = (int *) az_symbol_entry->b_value;
 
@@ -385,20 +386,20 @@ print_uil_widget(
     "%s %s(0x%lx) name: %s\n",
                  get_object_text(az_widget_entry->header.b_type),
                  get_tag_text(az_widget_entry->header.b_tag),
-                 az_widget_entry,
+                 (unsigned long) az_widget_entry,
                  wid_name);
 
     printf(
     "  controls: 0x%lx  callbacks: 0x%lx  arguments: 0x%lx  parent_list: 0x%lx\n",
-                 az_widget_entry->az_controls,
-                 az_widget_entry->az_callbacks,
-                 az_widget_entry->az_arguments,
-                 az_widget_entry->parent_list);
+                 (unsigned long) az_widget_entry->az_controls,
+                 (unsigned long) az_widget_entry->az_callbacks,
+                 (unsigned long) az_widget_entry->az_arguments,
+                 (unsigned long) az_widget_entry->parent_list);
 
     if (az_widget_entry->az_create_proc != NULL)
     {
        printf("  create proc: 0x%lx\n",
-                     az_widget_entry->az_create_proc);
+                     (unsigned long) az_widget_entry->az_create_proc);
     }
 }
 
@@ -520,8 +521,8 @@ print_uil_callback(
     printf(
     "  CALLBACK name: %s  proc ref: 0x%lx  proc ref list: 0x%lx\n",
                  name_str,
-                 az_callback_entry->az_call_proc_ref,
-                 az_callback_entry->az_call_proc_ref_list);
+                 (unsigned long) az_callback_entry->az_call_proc_ref,
+                 (unsigned long) az_callback_entry->az_call_proc_ref_list);
 }
 
 /*
@@ -538,7 +539,7 @@ print_uil_list(
 
     printf("%s LIST(0x%lx)  count: %d  gadget count: %d\n",
                  get_tag_text(az_list_entry->header.b_type),
-                 az_list_entry,
+                 (unsigned long) az_list_entry,
                  az_list_entry->w_count,
                  az_list_entry->w_gadget_count);
 }
@@ -552,10 +553,10 @@ print_uil_name(
 )
 {
     printf("NAME(0x%lx)  size: %d  next name: 0x%lx  object: 0x%lx",
-     az_name_entry,
+     (unsigned long) az_name_entry,
      az_name_entry->header.w_node_size,
-     az_name_entry->az_next_name_entry,
-     az_name_entry->az_object);
+     (unsigned long) az_name_entry->az_next_name_entry,
+     (unsigned long) az_name_entry->az_object);
 
     if (az_name_entry->b_flags & sym_m_referenced)
     {
@@ -575,8 +576,8 @@ print_uil_module(
 {
     printf("%s MODULE(0x%lx)  version: 0x%lx \n",
      az_module_entry->obj_header.az_name->c_text,
-     az_module_entry,
-     az_module_entry->az_version);
+     (unsigned long) az_module_entry,
+     (unsigned long) az_module_entry->az_version);
 }
 
 /*
@@ -589,12 +590,12 @@ print_uil_color_item(
 {
     printf(
     "COLOR ITEM(0x%lx)  size: %d  letter: %c  index: %d  color: 0x%lx  next: 0x%lx\n",
-     az_color_item_entry,
+     (unsigned long) az_color_item_entry,
      az_color_item_entry->header.w_node_size,
      az_color_item_entry->b_letter,
      az_color_item_entry->b_index,
-     az_color_item_entry->az_color,
-     az_color_item_entry->az_next);
+     (unsigned long) az_color_item_entry->az_color,
+     (unsigned long) az_color_item_entry->az_next);
 }
 
 /*
@@ -606,9 +607,9 @@ print_uil_parent_list_item(
 )
 {
     printf("PARENT LIST(0x%lx)  parent: 0x%lx  next: 0x%lx \n",
-     az_parent_list_item,
-     az_parent_list_item->parent,
-     az_parent_list_item->next);
+     (unsigned long) az_parent_list_item,
+     (unsigned long) az_parent_list_item->parent,
+     (unsigned long) az_parent_list_item->next);
 }
 
 /*
@@ -620,9 +621,9 @@ print_uil_external_def(
 )
 {
     printf("EXTERNAL DEF(0x%lx)  next external: 0x%lx  object: 0x%lx \n",
-     az_external_def_entry,
-     az_external_def_entry->az_next_object,
-     az_external_def_entry->az_name);
+     (unsigned long) az_external_def_entry,
+     (unsigned long) az_external_def_entry->az_next_object,
+     (unsigned long) az_external_def_entry->az_name);
 }
 
 /*
@@ -653,8 +654,8 @@ print_uil_proc_def(
        imported_flag = " imported";
 
     printf("PROC DEF(0x%lx)  name: 0x%lx %s%s%s%s  count: %d  %s\n",
-        az_proc_def_entry,
-        az_proc_def_entry->obj_header.az_name,
+        (unsigned long) az_proc_def_entry,
+        (unsigned long) az_proc_def_entry->obj_header.az_name,
         checking_flag,
         private_flag,
         exported_flag,
@@ -676,9 +677,9 @@ print_uil_proc_ref(
      */
 
     printf("PROC REF(0x%lx)  proc def: 0x%lx  value: 0x%lx\n",
-        az_proc_ref_entry,
-        az_proc_ref_entry->az_proc_def,
-        az_proc_ref_entry->az_arg_value);
+        (unsigned long) az_proc_ref_entry,
+        (unsigned long) az_proc_ref_entry->az_proc_def,
+        (unsigned long) az_proc_ref_entry->az_arg_value);
 }
 
 /*
@@ -691,14 +692,14 @@ print_uil_forward_ref(
 {
     printf(
     "FORWARD REF(0x%lx)  next ref: 0x%lx  location: 0x%lx  %s  parent: 0x%lx\n",
-     az_forward_ref_entry,
-     az_forward_ref_entry->az_next_ref,
-     az_forward_ref_entry->a_update_location,
+     (unsigned long) az_forward_ref_entry,
+     (unsigned long) az_forward_ref_entry->az_next_ref,
+     (unsigned long) az_forward_ref_entry->a_update_location,
      get_object_text(az_forward_ref_entry->header.b_type),
-     az_forward_ref_entry->parent);
+     (unsigned long) az_forward_ref_entry->parent);
 
     printf("  name: 0x%lx %s\n",
-        az_forward_ref_entry->az_name,
+        (unsigned long) az_forward_ref_entry->az_name,
         az_forward_ref_entry->az_name->c_text);
 }
 
@@ -732,9 +733,9 @@ print_uil_value(
        imported_flag = " imported";
 
     printf("  VALUE(0x%lx)  size: %d  name: 0x%lx  %s%s%s%s",
-        az_value_entry,
+        (unsigned long) az_value_entry,
         az_value_entry->header.w_node_size,
-        az_value_entry->obj_header.az_name,
+        (unsigned long) az_value_entry->obj_header.az_name,
         builtin_flag, private_flag, exported_flag, imported_flag);
 
     if (az_value_entry->obj_header.b_flags & sym_m_imported)
@@ -747,12 +748,12 @@ print_uil_value(
     {
       case sym_k_integer_value:
        printf("  integer: %d \n",
-                     az_value_entry->value.l_integer);
+                     (int)az_value_entry->value.l_integer);
        break;
 
       case sym_k_bool_value:
        printf("  boolean: %d \n",
-                     az_value_entry->value.l_integer);
+                     (int)az_value_entry->value.l_integer);
        break;
 
       case sym_k_float_value:
@@ -808,12 +809,12 @@ common_special_type:
 
       case sym_k_compound_string_value:
        printf("  compound string\n  first component: 0x%lx\n",
-                     az_value_entry->az_first_table_value);
+                     (unsigned long) az_value_entry->az_first_table_value);
 
        if ((az_value_entry->b_aux_flags & sym_m_table_entry) != 0)
        {
            printf("  next table entry: 0x%lx",
-                         az_value_entry->az_next_table_value);
+                         (unsigned long) az_value_entry->az_next_table_value);
        }
 
        break;
@@ -826,7 +827,7 @@ common_special_type:
                          get_charset_text(az_value_entry->b_charset));
        else
            printf("  font  charset: userdefined(%x)",
-                get_charset_text((long) az_value_entry->az_charset_value));
+                (unsigned) (uintptr_t) get_charset_text((long) az_value_entry->az_charset_value));
 
        goto check_for_table_value;
 
@@ -855,13 +856,13 @@ common_special_type:
                printf(
                "  string length: %d\n  charset: userdefined(%x)  L_TO_R",
                     az_value_entry->w_length,
-                    az_value_entry->az_charset_value);
+                    (unsigned) (uintptr_t) az_value_entry->az_charset_value);
                break;
              case XmSTRING_DIRECTION_R_TO_L:
                printf(
                "  string length: %d\n  charset: userdefined(%x)  R_TO_L",
                     az_value_entry->w_length,
-                    az_value_entry->az_charset_value);
+                    (unsigned) (uintptr_t) az_value_entry->az_charset_value);
                break;
            }
 
@@ -873,7 +874,7 @@ check_for_table_value:
        if ((az_value_entry->b_aux_flags & sym_m_table_entry) != 0)
        {
            printf("  next table entry: 0x%lx",
-                         az_value_entry->az_next_table_value);
+                         (unsigned long) az_value_entry->az_next_table_value);
        }
 
        output_text
@@ -890,8 +891,8 @@ check_for_table_value:
        printf("  icon  width: %d  height: %d  colors: 0x%lx  rows: 0x%lx \n",
                      az_value_entry->value.z_icon->w_width,
                      az_value_entry->value.z_icon->w_height,
-                     az_value_entry->value.z_icon->az_color_table,
-                     az_value_entry->value.z_icon->az_rows);
+                     (unsigned long) az_value_entry->value.z_icon->az_color_table,
+                     (unsigned long) az_value_entry->value.z_icon->az_rows);
 
        break;
 
@@ -909,7 +910,7 @@ check_for_table_value:
 common_table:
 
        printf("  %s  first table entry: 0x%lx\n",
-                     table_type, az_value_entry->az_first_table_value);
+                     table_type, (unsigned long) az_value_entry->az_first_table_value);
 
        break;
 
@@ -928,7 +929,7 @@ common_table:
                printf("    letter: %c  index: %d  color: 0x%lx\n",
                              az_value_entry->value.z_color[index].b_letter,
                              az_value_entry->value.z_color[index].b_index,
-                             az_value_entry->value.z_color[index].az_color);
+                             (unsigned long) az_value_entry->value.z_color[index].az_color);
            }
 
            break;
@@ -1009,22 +1010,22 @@ print_uil_obj_header(
 {
     printf("%s(0x%lx)",
      get_tag_text(az_obj_entry->header.b_tag),
-     az_obj_entry);
+     (unsigned long) az_obj_entry);
 
     if (az_obj_entry->obj_header.az_name != NULL)
     {
-       printf("  name: 0x%lx", az_obj_entry->obj_header.az_name);
+       printf("  name: 0x%lx", (unsigned long) az_obj_entry->obj_header.az_name);
     }
 
     if (az_obj_entry->obj_header.az_reference != NULL)
     {
        printf("  reference: 0x%lx",
-                     az_obj_entry->obj_header.az_reference);
+                     (unsigned long) az_obj_entry->obj_header.az_reference);
     }
 
     if (az_obj_entry->obj_header.az_next != NULL)
     {
-       printf("  next: 0x%lx", az_obj_entry->obj_header.az_next);
+       printf("  next: 0x%lx", (unsigned long) az_obj_entry->obj_header.az_next);
     }
 
     if (az_obj_entry->obj_header.b_flags & sym_m_private)
@@ -1052,7 +1053,7 @@ print_uil_include_file(
 )
 {
     printf("INCLUDE FILE(0x%lx)  file name: %s  full file name: %s\n",
-              az_symbol_entry,
+              (unsigned long) az_symbol_entry,
               az_symbol_entry->file_name, az_symbol_entry->full_file_name);
 }
 
@@ -1064,8 +1065,8 @@ print_uil_section(
 {
     printf("%s SECTION(0x%lx)  entries: 0x%lx\n",
                  get_sym_section_text(az_symbol_entry->header.b_type),
-                 az_symbol_entry,
-                 az_symbol_entry->entries);
+                 (unsigned long) az_symbol_entry,
+                 (unsigned long) az_symbol_entry->entries);
 }
 
 static void
@@ -1075,8 +1076,8 @@ print_uil_object_variant(
 {
     printf(
     "DEFAULT OBJ VAR(0x%lx)  next: 0x%lx  object info: %d, variant_info: %d\n",
-                 az_symbol_entry,
-                 az_symbol_entry->next, az_symbol_entry->b_object_info,
+                 (unsigned long) az_symbol_entry,
+                 (unsigned long) az_symbol_entry->next, az_symbol_entry->b_object_info,
                  az_symbol_entry->b_variant_info);
 }
 
@@ -1086,10 +1087,10 @@ print_uil_root_entry(
 )
 {
     printf("ROOT(0x%lx)  tag: %d  module: 0x%lx  sections: 0x%lx\n  module tail: ",
-                 az_symbol_entry,
+                 (unsigned long) az_symbol_entry,
                  az_symbol_entry->header.b_tag,
-                 az_symbol_entry->module_hdr,
-                 az_symbol_entry->sections);
+                 (unsigned long) az_symbol_entry->module_hdr,
+                 (unsigned long) az_symbol_entry->sections);
 }
 
 static char *
index 6e39ede98b19f091ee2cf195c76a47c287397b53..285b793671b8d4ef9e859f1eaf0ca1dbde42b935 100644 (file)
@@ -1275,7 +1275,7 @@ static BOOL               bil_token_table_inited = FALSE;
 /* 
  * Compares to entries (for qsort)
  */
-static long
+static int
 bil_token_entry_compare(const void *leftEntry, const void *rightEntry)
 {
     return ((long)(((BilTokenIndexEntry)leftEntry)->string))
index e39be3911ceb823c70eb868702cdeb36ecc36748..b2d0ede1f2347be59d8d24b3115b01671dab3511 100644 (file)
@@ -465,5 +465,5 @@ sprint(char *s)
 void
 bilP_reset_token_text(void)
 {
-    sprintf(tokenText, "");
+    sprintf(tokenText, "%s", "");
 }
index 89620fe64f1116dba22310eed94cc70ae06f79e8..66b89fb343fc20165d94618c30c68bd97577b012 100644 (file)
@@ -209,7 +209,7 @@ bil_load_file(
     if (bilP_load.project == NULL)
     {
        LoadErr = TRUE;
-       sprintf(Buf, catgets(ABIL_MESSAGE_CATD, ABIL_MESSAGE_SET, 39,
+       sprintf(Buf, "%s", catgets(ABIL_MESSAGE_CATD, ABIL_MESSAGE_SET, 39,
                "Unable to load project."));
        errmsg = Buf;
        goto epilogue;
index 8b873161ae0ffc26e283b10b9f3260945b533e41..c367afbafe41c2f4fa329503c0d58583467cc59e 100644 (file)
@@ -709,7 +709,7 @@ obj_get_safe_name(ABObj obj, STRING name, int name_size)
     else if (obj_get_name(obj) == NULL)
     {
        char                buf[256];
-       sprintf(buf, "(ABObj:0x%08lx)", obj);
+       sprintf(buf, "(ABObj:0x%08lx)", (unsigned long) obj);
        strncpy(name, buf, name_size);
     }
     else
index 37cd41cba1bf3318e0b53992ba36bd74c84fae7a..90d1c096dc650ec1a58a216f67d544ddaa806fb4 100644 (file)
@@ -1018,7 +1018,7 @@ event_print(OBJ_EVENT *event, FILE *outFile, BOOL addNewline, STRING name)
            sprintf(eventParams, "(%s %d 0x%08lx)",
                obj_get_safe_name(obj, buf1, 256),
                event->info.update_with_data.update_code,
-               event->info.update_with_data.update_data);
+               (unsigned long) event->info.update_with_data.update_data);
        break;
 
        default:
@@ -1030,7 +1030,7 @@ event_print(OBJ_EVENT *event, FILE *outFile, BOOL addNewline, STRING name)
     if (*eventParams == 0)
     {
        char    objName[1024];
-       sprintf(objName, "(%#lx", obj);
+       sprintf(objName, "(%#lx", (unsigned long) obj);
        if (obj_get_name(obj) != NULL)
        {
            strcat(objName, " = ");
index cd08c837ccf263c3c9daee327f4954fd435db118..bb34c5cb68d3e12b86234a008ef9588641ab6443 100644 (file)
@@ -1197,7 +1197,7 @@ obj_verify(ABObj obj)
        if (ok)
        {
            obj_str_ptr_name = istr_string(obj->name);
-           sprintf((STRING)obj_name, "(ABObj %#lx", obj);
+           sprintf((STRING)obj_name, "(ABObj %#lx", (unsigned long) obj);
            if (obj_str_ptr_name != NULL)
            {
                strcat((STRING)obj_name, " = ");
@@ -1212,7 +1212,7 @@ obj_verify(ABObj obj)
     }
     else
     {
-       sprintf((STRING)obj_name, "(ABObj %#lx)", obj);
+       sprintf((STRING)obj_name, "(ABObj %#lx)", (unsigned long) obj);
        field_err("name");
     }
 
index 9a0358eadea418a21ae4775240208092b39b1f45..f7f8d29c09da06ea5236584eb5fae77d0426ad2c 100644 (file)
@@ -308,7 +308,7 @@ xm_configure_tree(
 
     if (configCount!= numSalientObjs)
     {
-       fprintf(stderr, 
+       fprintf(stderr, "%s",
            catgets(OBJXM_MESSAGE_CATD, OBJXM_MESSAGE_SET, 8,
               "INTERNAL ERROR: salient counts don't match.\n") );
        iRetVal= -1;
index 89a98cce25bf4c5d589ea18470644c6d1e601a59..98a16f16ccc91da20f3d6952b90c5bc34f01a888 100644 (file)
@@ -1052,7 +1052,7 @@ load_res_table(
 }
 
 
-static long
+static int
 xm_res_table_entry_xmname_compare(const void *leftEntry, const void *rightEntry)
 {
     return 
index 81af6d10b6b5106321a5f84045c344bcf4cd5990..6206ba1bc1933068f7426be67995cfaabb89eef1 100644 (file)
@@ -166,7 +166,7 @@ istr_create (
                     entry->values[i] = num_count;
                     if (insert_array(1,num_count, string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL;
@@ -179,7 +179,7 @@ istr_create (
                 {   /* take int value from freelist */
                     if(int_array[freelist[freecount-1]].refcount != 0)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                             "ISTR: error in allocating space for string\n") );
                         return NULL;
@@ -187,7 +187,7 @@ istr_create (
                     entry->values[i] = freelist[freecount-1];
                     if (insert_array(1,freelist[freecount-1], string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL; 
@@ -209,7 +209,7 @@ istr_create (
                         entry->values[i] = num_count;
                         if (insert_array(1, num_count, string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -222,7 +222,7 @@ istr_create (
                     {
                         if(int_array[freelist[freecount-1]].refcount != 0)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                                 "ISTR: error in allocating space for string\n") );
                             return NULL;
@@ -231,7 +231,7 @@ istr_create (
                         if (insert_array(1, 
                             freelist[freecount-1], string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -247,7 +247,7 @@ istr_create (
         new_bucket = (Bucket)malloc (sizeof(BucketRec));
         if (new_bucket == NULL)
         {
-            fprintf(stderr,
+            fprintf(stderr, "%s",
                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                "ISTR: error in allocating memory\n") );
             return NULL ;
@@ -261,7 +261,7 @@ istr_create (
             entry->next = new_bucket;
             if (insert_array(1, num_count, string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -274,7 +274,7 @@ istr_create (
         {
             if(int_array[freelist[freecount-1]].refcount != 0)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                    "ISTR: error in allocating space for string\n") );
                 return NULL;
@@ -283,7 +283,7 @@ istr_create (
             entry->next = new_bucket;
             if (insert_array(1, freelist[freecount-1], string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -335,7 +335,7 @@ istrP_create_alloced_impl(
                     entry->values[i] = num_count;
                     if (insert_array(3,num_count, *string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL;
@@ -348,7 +348,7 @@ istrP_create_alloced_impl(
                 {   /* take int value from freelist */
                     if(int_array[freelist[freecount-1]].refcount != 0)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                             "ISTR: error in allocating space for string\n") );
                         return NULL;
@@ -356,7 +356,7 @@ istrP_create_alloced_impl(
                     entry->values[i] = freelist[freecount-1];
                     if (insert_array(3,freelist[freecount-1], *string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL;
@@ -378,7 +378,7 @@ istrP_create_alloced_impl(
                         entry->values[i] = num_count;
                         if (insert_array(3, num_count, *string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -391,7 +391,7 @@ istrP_create_alloced_impl(
                     {
                         if(int_array[freelist[freecount-1]].refcount != 0)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                                 "ISTR: error in allocating space for string\n") );
                             return NULL;
@@ -400,7 +400,7 @@ istrP_create_alloced_impl(
                         if (insert_array(3, 
                             freelist[freecount-1], *string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -416,7 +416,7 @@ istrP_create_alloced_impl(
         new_bucket = (Bucket)malloc (sizeof(BucketRec));
         if (new_bucket == NULL)
         {
-            fprintf(stderr,
+            fprintf(stderr, "%s",
                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                "ISTR: error in allocating memory\n") );
             return NULL ;
@@ -430,7 +430,7 @@ istrP_create_alloced_impl(
             entry->next = new_bucket;
             if (insert_array(3, num_count, *string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -443,7 +443,7 @@ istrP_create_alloced_impl(
         {
             if(int_array[freelist[freecount-1]].refcount != 0)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                    "ISTR: error in allocating space for string\n") );
                 return NULL;
@@ -452,7 +452,7 @@ istrP_create_alloced_impl(
             entry->next = new_bucket;
             if (insert_array(3, freelist[freecount-1], *string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -512,7 +512,7 @@ istr_create_const(
                     entry->values[i] = num_count;
                     if (insert_array(2, num_count, string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL;
@@ -525,7 +525,7 @@ istr_create_const(
                 {   /* take int value from freelist */
                     if(int_array[freelist[freecount-1]].refcount != 0)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                             "ISTR: error in allocating space for string\n") );
                         return NULL;
@@ -533,7 +533,7 @@ istr_create_const(
                     entry->values[i] = freelist[freecount-1];
                     if (insert_array(2, freelist[freecount-1], string) == -1)
                     {
-                        fprintf(stderr,
+                        fprintf(stderr, "%s",
                            catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                             "ISTR: error in allocating to int array\n") );
                         return NULL;
@@ -555,7 +555,7 @@ istr_create_const(
                         entry->values[i] = num_count;
                         if (insert_array(2, num_count, string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -568,7 +568,7 @@ istr_create_const(
                     {
                         if(int_array[freelist[freecount-1]].refcount != 0)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                                 "ISTR: error in allocating space for string\n") );
                             return NULL;
@@ -577,7 +577,7 @@ istr_create_const(
                         if (insert_array(2, 
                             freelist[freecount-1], string) == -1)
                         {
-                            fprintf(stderr,
+                            fprintf(stderr, "%s",
                                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                                 "ISTR: error in allocating to int array\n") );
                             return NULL;
@@ -593,7 +593,7 @@ istr_create_const(
         new_bucket = (Bucket)malloc (sizeof(BucketRec));
         if (new_bucket == NULL)
         {
-            fprintf(stderr,
+            fprintf(stderr, "%s",
                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                "ISTR: error in allocating memory\n") );
             return NULL ;
@@ -609,7 +609,7 @@ istr_create_const(
             entry->next = new_bucket;
             if (insert_array(2, num_count, string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -622,7 +622,7 @@ istr_create_const(
         {
             if(int_array[freelist[freecount-1]].refcount != 0)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 2,
                    "ISTR: error in allocating space for string\n") );
                 return NULL;
@@ -631,7 +631,7 @@ istr_create_const(
             entry->next = new_bucket;
             if (insert_array(2, freelist[freecount-1], string) == -1)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 1,
                    "ISTR: error in allocating to int array\n") );
                 return NULL;
@@ -755,7 +755,7 @@ istrP_destroy_impl(
             freelist = (long *)malloc(ARRAYSIZE * sizeof(long));
             if (freelist == NULL)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                    "ISTR: error in allocating memory\n") );
                 return 0 ;
@@ -776,7 +776,7 @@ istrP_destroy_impl(
            assert(freelist != NULL);
             if (freelist == NULL)
             {
-                fprintf(stderr,
+                fprintf(stderr, "%s",
                    catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                    "ISTR: error in allocating memory\n") );
                 return 0 ;
@@ -935,7 +935,7 @@ insert_array(
         int_array_set((STRN *)calloc(ARRAYSIZE, sizeof(STRN)));
         if (int_array == NULL)
         {
-            fprintf(stderr,
+            fprintf(stderr, "%s",
                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                "ISTR: error in allocating memory\n") );
             return 0 ;
@@ -970,7 +970,7 @@ insert_array(
        assert(int_array != NULL);
         if (int_array == NULL)
         {
-            fprintf(stderr,
+            fprintf(stderr, "%s",
                catgets(UTIL_MESSAGE_CATD, UTIL_MESSAGE_SET, 3,
                "ISTR: error in allocating memory\n") );
             return 0 ;
index 12e9e02aa8cadad8ea456158fc9c42fa9b6f08aa..52aebe8c3dcbe623c9f2a45ff61056e811931a28 100644 (file)
@@ -432,7 +432,7 @@ util_cvt_path_to_relative(
        }
        else
        {
-           while ((*rightmost_slash == '/') && (*rightmost_slash != NULL))
+           while ((*rightmost_slash == '/') && (*rightmost_slash != 0))
            {
                ++rightmost_slash;
            }