dtpdm: Coverity 87632, 87664, 87923
authorPeter Howkins <flibble@users.sf.net>
Mon, 23 Apr 2018 02:43:48 +0000 (03:43 +0100)
committerPeter Howkins <flibble@users.sf.net>
Mon, 23 Apr 2018 02:43:48 +0000 (03:43 +0100)
cde/programs/dtpdm/MainWindow.c
cde/programs/dtpdm/MainWindow.h
cde/programs/dtpdm/PdmXp.c
cde/programs/dtpdm/PrinterBox.c

index cacb12d790e88d5f938e2d0c7a2d1508d9acabcf..a21f6ad5a107879ed568f2428ae36a24e8a5e08f 100644 (file)
@@ -156,7 +156,7 @@ PdmMainWinDelete(PdmMainWin* me)
  *     The passed PdmSetupBox pointer.
  *
  */
-PdmSetupBox*
+void
 PdmMainWinAddSetupBox(PdmMainWin* me, PdmSetupBox* box)
 {
     /*
index 73fde56b2caadebe1fe2d149579697524824bef5..386fb76de6ada7cceaa9e7b8fbe6d7a14fcffaa1 100644 (file)
@@ -139,7 +139,7 @@ PdmMainWin* PdmMainWinCreate(
                             String print_display_spec,
                             String print_context_str);
 void PdmMainWinDelete(PdmMainWin* me);
-PdmSetupBox* PdmMainWinAddSetupBox(PdmMainWin* me, PdmSetupBox* box);
+void PdmMainWinAddSetupBox(PdmMainWin* me, PdmSetupBox* box);
 String* PdmMainWinMergeFallbacks(PdmMainWin* me,
                                 const String* app_fallbacks,
                                 int count);
index 3cd65d5c42f64f900c9617a0d6c5912caf05cb56..8fd7f284ba6f81b0d9294ec82ebed483ca0f6070 100644 (file)
@@ -181,7 +181,7 @@ PdmXpClose(PdmXp* me)
            if(me->pool[i] != (XrmDatabase)NULL)
            {
                XrmDestroyDatabase(me->pool[i]);
-               me->pool[i] == (XrmDatabase)NULL;
+               me->pool[i] = (XrmDatabase)NULL;
            }
        }
        XCloseDisplay(me->display);
index 6c418c0932fca7c753363303562c42c9304c14f8..7c06d0106e15b44a24eae1e0221837860367125b 100644 (file)
@@ -3225,7 +3225,7 @@ PdmPixmapListGetPixmap(PdmPixmapList* me, int i)
                                    me->foreground, me->background);
        if(me->pixmap[i] == XmUNSPECIFIED_PIXMAP)
        {
-           me->pixmap[i] == None;
+           me->pixmap[i] = None;
        }
        else if(me->stipple != None)
        {