Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1198306
| From | Adrian Remonda <adrianremonda@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCHv2 4/6] Staging: most: Fix sparse warning "Using plain integer as NULL pointer" |
| Date | 2015-08-02 22:10 +0200 |
| Message-ID | <pT7K2-5VF-15@gated-at.bofh.it> (permalink) |
| References | <pT7K2-5VF-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
This patch fixes the warning generated by sparse: "Using plain integer
as NULL pointer" by replacing the offending 0 with NULL.
Signed-off-by: Adrian Remonda <adrianremonda@gmail.com>
---
drivers/staging/most/hdm-dim2/dim2_hal.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/most/hdm-dim2/dim2_hal.c b/drivers/staging/most/hdm-dim2/dim2_hal.c
index 01b748944ee4..a54cf2cedac3 100644
--- a/drivers/staging/most/hdm-dim2/dim2_hal.c
+++ b/drivers/staging/most/hdm-dim2/dim2_hal.c
@@ -889,7 +889,7 @@ struct dim_ch_state_t *DIM_GetChannelState(struct dim_channel *ch,
struct dim_ch_state_t *state_ptr)
{
if (!ch || !state_ptr)
- return 0;
+ return NULL;
state_ptr->ready = ch->state.level < 2;
state_ptr->done_buffers = ch->done_sw_buffers_number;
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCHv2 0/6] Staging: most: several warnings fix reported by sparse Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 6/6] Staging: most: Fix sparse warning "Using plain integer as NULL pointer" Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 5/6] Staging: most: static keyword missing Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 2/6] Staging: most: Fix sparse warning "Using plain integer as NULL pointer" Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 4/6] Staging: most: Fix sparse warning "Using plain integer as NULL pointer" Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 3/6] Staging: most: static keyword missing Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 [PATCHv2 1/6] Staging: most: static keyword missing Adrian Remonda <adrianremonda@gmail.com> - 2015-08-02 22:10 +0200 Re: [PATCHv2 0/6] Staging: most: several warnings fix reported by sparse Greg KH <gregkh@linuxfoundation.org> - 2015-08-02 23:20 +0200
csiph-web