11132 libsysevent: NULL pointer errors

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

Information
Toomas Soome
illumos-gate
11132
363999d...
Reviewers
general
../libevchannel.c: In function 'sysevent_evc_unbind':
../libevchannel.c:220:18: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
   uargs.sid.name = NULL;
                  ^
../libevchannel.c: In function 'sysevent_evc_unsubscribe':
../libevchannel.c:708:18: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
   uargs.sid.name = NULL;
                  ^

../libsysevent.c: In function 'subscriber_event_handler':
../libsysevent.c:767:31: error: comparison between pointer and integer [-Werror]
  if (sub_info->sp_handler_tid == 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 ../libsysevent.c:26:
../libsysevent.c: In function 'sysevent_bind_subscriber_cmn':
/code/illumos-gate/proto/root_i386/usr/include/sys/null.h:32:14: error: passing argument 2 of 'thr_create' makes integer from pointer without a cast [-Werror=int-conversion]
 #define NULL ((void *)0)
              ^
../libsysevent.c:2222:30: note: in expansion of macro 'NULL'
   created = thr_create(NULL, NULL,
                              ^~~~
In file included from ../libsysevent.c:38:0:
/code/illumos-gate/proto/root_i386/usr/include/thread.h:54:12: note: expected 'size_t {aka unsigned int}' but argument is of type 'void *'
 extern int thr_create(void *, size_t, void *(*)(void *), void *, long,
            ^~~~~~~~~~
../libsysevent.c: In function 'sysevent_unbind_subscriber':
../libsysevent.c:2511:31: error: comparison between pointer and integer [-Werror]
  if (sub_info->sp_handler_tid != NULL)
                               ^~
cc1: all warnings being treated as errors

  

Issues

  • 0
  • 2
  • 0
  • 2
Description From Last Updated
John Levon
Toomas Soome
John Levon
Toomas Soome
John Levon
Toomas Soome
Toomas Soome
Review request changed

Status: Closed (submitted)

Loading...