10738 sockfs: NULL pointer errors

Review Request #1704 - Created April 11, 2019 and submitted

Information
Toomas Soome
illumos-gate
10738
cf19d38...
Reviewers
general
In file included from ../../common/sys/param.h:48:0,
                 from ../../common/sys/sysmacros.h:37,
                 from ../../common/fs/sockfs/nl7chttp.c:26:
../../common/sys/null.h:32:14: error: initialization makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
./nl7ctokgen.h:88:3: note: in expansion of macro 'NULL'
  {NULL}
   ^~~~
../../common/sys/null.h:32:14: note: (near initialization for 'tokreq[16].tokid')
 #define NULL ((void *)0)
              ^
./nl7ctokgen.h:88:3: note: in expansion of macro 'NULL'
  {NULL}
   ^~~~
../../common/sys/null.h:32:14: error: initialization makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
./nl7ctokgen.h:110:3: note: in expansion of macro 'NULL'
  {NULL}
   ^~~~
../../common/sys/null.h:32:14: note: (near initialization for 'tokres[15].tokid')
 #define NULL ((void *)0)
              ^
./nl7ctokgen.h:110:3: note: in expansion of macro 'NULL'
  {NULL}
   ^~~~

../../common/fs/sockfs/nl7c.c: In function 'atou':
../../common/fs/sockfs/nl7c.c:282:20: error: comparison between pointer and integer [-Werror]
  while ((c = *p++) != NULL && isdigit(c)) {
                    ^~
../../common/fs/sockfs/nl7c.c: In function 'ncaportconf_read':
../../common/fs/sockfs/nl7c.c:420:14: error: comparison between pointer and integer [-Werror]
     if (*tok != NULL) {
              ^~
../../common/fs/sockfs/nl7c.c:438:14: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
     *stringp = NULL;
              ^
../../common/fs/sockfs/nl7c.c:473:14: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
     *stringp = NULL;
              ^
../../common/fs/sockfs/nl7c.c: In function 'ncakmodconf_read':
../../common/fs/sockfs/nl7c.c:585:14: error: comparison between pointer and integer [-Werror]
     if (*tok == NULL) {
              ^~
../../common/fs/sockfs/nl7c.c: In function 'ncalogdconf_read':
../../common/fs/sockfs/nl7c.c:724:43: error: comparison between pointer and integer [-Werror]
     if (tokstatusp != NULL && *tokstatusp == NULL)
                                           ^~
../../common/fs/sockfs/nl7c.c:726:44: error: comparison between pointer and integer [-Werror]
     else if (toksizep != NULL && *toksizep == NULL)
                                            ^~
../../common/fs/sockfs/nl7c.c:728:44: error: comparison between pointer and integer [-Werror]
     else if (tokfilep != NULL && *tokfilep == NULL)
                                            ^~
../../common/fs/sockfs/nl7c.c:749:24: error: comparison between pointer and integer [-Werror]
      if (*++tokstatusp == NULL)
                        ^~
../../common/fs/sockfs/nl7c.c:764:39: error: comparison between pointer and integer [-Werror]
     if (! isalpha(c) || *++tokstatusp == NULL ||
                                       ^~

../../common/fs/sockfs/nl7curi.c: In function 'uri_lookup':
../../common/fs/sockfs/nl7curi.c:929:32: error: wrong type argument to bit-complement
  ruri->proc = (struct sonode *)~NULL;
                                ^

../../common/fs/sockfs/socktpi.c: In function 'socktpi_plumbioctl':
../../common/fs/sockfs/socktpi.c:6204:11: error: comparison between pointer and integer [-Werror]
   if (arg == NULL) {
           ^~
cc1: all warnings being treated as errors

  

Issues

  • 0
  • 1
  • 1
  • 2
Description From Last Updated
Robert Mustacchi
Toomas Soome
Robert Mustacchi
Andy Fiddaman
Andy Fiddaman
Toomas Soome
Toomas Soome
Review request changed

Status: Closed (submitted)

Loading...