Project

General

Profile

Bug #11399

nlsadmin: NULL pointer errors

Added by Toomas Soome 3 months ago. Updated 3 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
cmd - userland programs
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Build errors with NULL pointer:

    nlsadmin.c: In function 'main':
    nlsadmin.c:359:10: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
        *ptr2 = NULL;
              ^
    nlsadmin.c: In function 'prt_cmd':
    nlsadmin.c:558:8: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       *tmp = NULL;
            ^
    nlsadmin.c: In function 'old_addsvc':
    nlsadmin.c:603:8: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       *tmp = NULL;
            ^
    nlsadmin.c: In function 'prt_nets':
    nlsadmin.c:696:32: error: comparison between pointer and integer [-Werror]
       if (strcmp(state, "ENABLED") == NULL ||
                                    ^~
    nlsadmin.c:697:33: error: comparison between pointer and integer [-Werror]
           strcmp(state, "STARTING") == NULL) {
                                     ^~
    nlsadmin.c: In function 'svc_format':
    nlsadmin.c:1251:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1255:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1263:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1267:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1271:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1275:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1279:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1283:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1287:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1291:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1300:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1304:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    nlsadmin.c:1308:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
      *ptr++ = NULL;
             ^
    cc1: all warnings being treated as errors

History

#1

Updated by Electric Monk 3 months ago

  • % Done changed from 90 to 100
  • Status changed from In Progress to Closed

git commit 67e41408d084203975c5d9837341aacd83b245c8

commit  67e41408d084203975c5d9837341aacd83b245c8
Author: Toomas Soome <tsoome@me.com>
Date:   2019-07-26T05:07:30.000Z

    11399 nlsadmin: NULL pointer errors
    Reviewed by: Andy Fiddaman <andy@omniosce.org>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF