diff options
author | Joe Simmons-Talbott <joetalbott@gmail.com> | 2022-07-18 04:03:48 +0200 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2022-07-18 19:29:30 +0200 |
commit | 295cc4268bb946a84f7681a9f032ade09a4087f8 (patch) | |
tree | c0d6c1f91ee21205a0a852fe67c5fa1064077e93 /drivers/iio/industrialio-trigger.c | |
parent | iio: Use parens with sizeof (diff) | |
download | linux-295cc4268bb946a84f7681a9f032ade09a4087f8.tar.xz linux-295cc4268bb946a84f7681a9f032ade09a4087f8.zip |
iio: Be consistent with allocation result tests.
Make both allocation result tests use the same format
if (!ptr)
Signed-off-by: Joe Simmons-Talbott <joetalbott@gmail.com>
Link: https://lore.kernel.org/r/20220718020348.32047-1-joetalbott@gmail.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/industrialio-trigger.c')
-rw-r--r-- | drivers/iio/industrialio-trigger.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/industrialio-trigger.c b/drivers/iio/industrialio-trigger.c index 3e1b1fbc66d0..b78814d869b7 100644 --- a/drivers/iio/industrialio-trigger.c +++ b/drivers/iio/industrialio-trigger.c @@ -365,7 +365,7 @@ struct iio_poll_func struct iio_poll_func *pf; pf = kmalloc(sizeof(*pf), GFP_KERNEL); - if (pf == NULL) + if (!pf) return NULL; va_start(vargs, fmt); pf->name = kvasprintf(GFP_KERNEL, fmt, vargs); |