Project

General

Profile

Bug #11437

uadmin: NULL pointer errors

Added by Toomas Soome about 1 month ago. Updated 24 days 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:

    In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/time_iso.h:49:0,
                     from /code/illumos-gate/proto/root_i386/usr/include/time.h:40,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/time.h:462,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/select.h:53,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/types.h:640,
                     from /code/illumos-gate/proto/root_i386/usr/include/fcntl.h:39,
                     from uadmin.c:31:
    uadmin.c: In function 'main':
    /code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: initialization makes integer from pointer without a cast [-Werror=int-conversion]
     #define NULL ((void *)0)
                  ^
    uadmin.c:63:19: note: in expansion of macro 'NULL'
      uintptr_t mdep = NULL;
                       ^~~~
    uadmin.c:155:8: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       mdep = NULL; /* Ignore all arguments */
            ^
    uadmin.c:163:8: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       mdep = NULL; /* Ignore all arguments */
            ^
    In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/time_iso.h:49:0,
                     from /code/illumos-gate/proto/root_i386/usr/include/time.h:40,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/time.h:462,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/select.h:53,
                     from /code/illumos-gate/proto/root_i386/usr/include/sys/types.h:640,
                     from /code/illumos-gate/proto/root_i386/usr/include/fcntl.h:39,
                     from uadmin.c:31:
    uadmin.c: In function 'wait_for_auqueue':
    /code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'auditon' makes integer from pointer without a cast [-Werror=int-conversion]
     #define NULL ((void *)0)
                  ^
    uadmin.c:438:60: note: in expansion of macro 'NULL'
      while (retries-- && auditon(A_GETSTAT, (caddr_t)&au_stat, NULL) == 0) {
                                                                ^~~~
    In file included from /code/illumos-gate/proto/root_i386/usr/include/bsm/adt.h:34:0,
                     from uadmin.c:42:
    /code/illumos-gate/proto/root_i386/usr/include/bsm/libbsm.h:188:12: note: expected 'int' but argument is of type 'void *'
     extern int auditon(int, caddr_t, int);
                ^~~~~~~
    cc1: all warnings being treated as errors

History

#1

Updated by Electric Monk 24 days ago

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

git commit 974925512dfb8d6b72662ec04481adc913c6f914

commit  974925512dfb8d6b72662ec04481adc913c6f914
Author: Toomas Soome <tsoome@me.com>
Date:   2019-07-30T20:00:47.000Z

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

Also available in: Atom PDF