11156 libzfs: NULL pointer errors

Review Request #1941 - Created June 1, 2019 and submitted

Information
Toomas Soome
illumos-gate
11156
0141e91...
Reviewers
general
../common/libzfs_util.c: In function 'zcmd_free_nvlists':
../common/libzfs_util.c:790:21: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
  zc->zc_nvlist_conf = NULL;
                     ^
../common/libzfs_util.c:791:20: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
  zc->zc_nvlist_src = NULL;
                    ^
../common/libzfs_util.c:792:20: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
  zc->zc_nvlist_dst = NULL;
                    ^

../common/libzfs_sendrecv.c: In function 'zfs_receive_one':
../common/libzfs_sendrecv.c:3190:42: error: comparison between pointer and integer [-Werror]
  stream_wantsnewfs = (drrb->drr_fromguid == NULL ||
                                          ^~

In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
../common/libzfs_dataset.c: In function 'zfs_prop_get':
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2595:24: note: in expansion of macro 'NULL'
   zcp_check(zhp, prop, NULL, propbuf);
                        ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2603:24: note: in expansion of macro 'NULL'
   zcp_check(zhp, prop, NULL, str);
                        ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2693:24: note: in expansion of macro 'NULL'
   zcp_check(zhp, prop, NULL, propbuf);
                        ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2719:24: note: in expansion of macro 'NULL'
   zcp_check(zhp, prop, NULL, propbuf);
                        ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2796:25: note: in expansion of macro 'NULL'
    zcp_check(zhp, prop, NULL, str);
                         ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
In file included from /code/illumos-gate/proto/root_i386/usr/include/iso/stdio_iso.h:53:0,
                 from /code/illumos-gate/proto/root_i386/usr/include/stdio.h:82,
                 from ../common/libzfs_dataset.c:40:
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:28:14: error: passing argument 3 of 'zcp_check' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../common/libzfs_dataset.c:2807:25: note: in expansion of macro 'NULL'
    zcp_check(zhp, prop, NULL, strval);
                         ^~~~
../common/libzfs_dataset.c:2418:1: note: expected 'uint64_t {aka long long unsigned int}' but argument is of type 'void *'
 zcp_check(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t intval,
 ^~~~~~~~~
cc1: all warnings being treated as errors

  
John Levon
Toomas Soome
John Levon
Toomas Soome
Review request changed

Status: Closed (submitted)

Loading...