Actions
Bug #10873
closedecpp: comparison between pointer and integer
Start date:
2019-04-28
Due date:
% Done:
100%
Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
Description
Debug build errors with NULL pointer:
In file included from ../../common/sys/model.h:35:0, from ../../common/sys/file.h:37, from ../../common/io/ecpp.c:35: ../../common/io/ecpp.c: In function 'dma8237_dma_start': ../../common/io/ecpp.c:5946:34: error: comparison between pointer and integer [- Werror] pp->dma_cookie.dmac_address != NULL); ^ ../../common/sys/debug.h:59:29: note: in definition of macro 'ASSERT' #define ASSERT(EX) ((void)((EX) || assfail(#EX, __FILE__, __LINE__))) ^~ ../../common/io/ecpp.c: In function 'x86_dma_start': ../../common/io/ecpp.c:6019:34: error: comparison between pointer and integer [- Werror] pp->dma_cookie.dmac_address != NULL); ^ ../../common/sys/debug.h:59:29: note: in definition of macro 'ASSERT' #define ASSERT(EX) ((void)((EX) || assfail(#EX, __FILE__, __LINE__))) ^~ cc1: all warnings being treated as errors commit aba324bf4b916cac0c38f9b340ac55772e882b06 Author: Toomas Soome <tsoome@me.com> Date: Sat Apr 27 21:35:36 2019 +0300 bpf: comparison between pointer and integer In file included from ../../common/sys/model.h:35:0, from ../../common/sys/resource.h:221, from ../../common/sys/user.h:73, from ../../common/sys/proc.h:36, from ../../common/sys/systm.h:40, from ../../common/io/bpf/bpf.c:68: ../../common/io/bpf/bpf.c: In function 'bpf_attachd': ../../common/io/bpf/bpf.c:255:19: error: comparison between pointer and integer [-Werror] ASSERT(d->bd_bif == NULL); ^ ../../common/sys/debug.h:59:29: note: in definition of macro 'ASSERT' #define ASSERT(EX) ((void)((EX) || assfail(#EX, __FILE__, __LINE__))) ^~ ../../common/io/bpf/bpf.c:256:20: error: comparison between pointer and integer [-Werror] ASSERT(d->bd_mcip == NULL); ^ ../../common/sys/debug.h:59:29: note: in definition of macro 'ASSERT' #define ASSERT(EX) ((void)((EX) || assfail(#EX, __FILE__, __LINE__))) ^~ 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 61d4f4d1a4dc2597f03bfddec03ec79efa5abd6b
commit 61d4f4d1a4dc2597f03bfddec03ec79efa5abd6b Author: Toomas Soome <tsoome@me.com> Date: 2019-05-16T19:20:40.000Z 10873 ecpp: comparison between pointer and integer Reviewed by: Rob Johnston <rob.johnston@joyent.com> Approved by: Dan McDonald <danmcd@joyent.com>
Actions