Actions
Bug #10389
closedcn: NULL pointer errors
Start date:
2019-02-11
Due date:
% Done:
100%
Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
Description
Build error with NULL pointer:
In file included from ../../common/sys/param.h:48:0, from ../../common/io/cons.c:43: ../../common/io/cons.c: In function 'cn_attach': ../../common/sys/null.h:32:14: error: passing argument 6 of 'ddi_create_minor_node' makes integer from pointer without a cast [-Werror=int-conversion] #define NULL ((void *)0) ^ ../../common/io/cons.c:210:21: note: in expansion of macro 'NULL' 0, DDI_PSEUDO, NULL) == DDI_FAILURE) { ^~~~ In file included from ../../common/io/cons.c:68:0: ../../common/sys/sunddi.h:1564:1: note: expected 'int' but argument is of type 'void *' ddi_create_minor_node(dev_info_t *dip, char *name, int spec_type, ^~~~~~~~~~~~~~~~~~~~~ In file included from ../../common/sys/param.h:48:0, from ../../common/io/cons.c:43: ../../common/sys/null.h:32:14: error: passing argument 6 of 'ddi_create_minor_node' makes integer from pointer without a cast [-Werror=int-conversion] #define NULL ((void *)0) ^ ../../common/io/cons.c:214:21: note: in expansion of macro 'NULL' 0, DDI_PSEUDO, NULL) == DDI_FAILURE) { ^~~~ In file included from ../../common/io/cons.c:68:0: ../../common/sys/sunddi.h:1564:1: note: expected 'int' but argument is of type 'void *' ddi_create_minor_node(dev_info_t *dip, char *name, int spec_type, ^~~~~~~~~~~~~~~~~~~~~ In file included from ../../common/sys/param.h:48:0, from ../../common/io/cons.c:43: ../../common/sys/null.h:32:14: error: passing argument 6 of 'ddi_create_minor_node' makes integer from pointer without a cast [-Werror=int-conversion] #define NULL ((void *)0) ^ ../../common/io/cons.c:219:21: note: in expansion of macro 'NULL' 0, DDI_PSEUDO, NULL) == DDI_FAILURE) { ^~~~ In file included from ../../common/io/cons.c:68:0: ../../common/sys/sunddi.h:1564:1: note: expected 'int' but argument is of type 'void *' ddi_create_minor_node(dev_info_t *dip, char *name, int spec_type, ^~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors
Updated by Electric Monk over 3 years ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100
git commit a64c6771e32828fb411900a3d0921d4da3c4459c
commit a64c6771e32828fb411900a3d0921d4da3c4459c Author: Toomas Soome <tsoome@me.com> Date: 2019-02-16T08:09:43.000Z 10389 cn: NULL pointer errors Reviewed by: Andy Fiddaman <andy@omniosce.org> Reviewed by: Andy Stormont <astormont@racktopsystems.com> Reviewed by: Gergő Mihály Doma <domag02@gmail.com> Approved by: Robert Mustacchi <rm@joyent.com>
Actions