diff options
author | simran singhal <singhalsimran0@gmail.com> | 2017-03-10 10:43:10 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-03-12 14:57:00 +0100 |
commit | 9573878611f4dd4d7be2e649814bef3270f4e5bd (patch) | |
tree | 1c749d63c943fc0544b93b08b80ef8c41736585c /samples | |
parent | 7cf51d34af7ad86fc14bbc2217d733f271e396e7 (diff) | |
download | op-kernel-dev-9573878611f4dd4d7be2e649814bef3270f4e5bd.zip op-kernel-dev-9573878611f4dd4d7be2e649814bef3270f4e5bd.tar.gz |
staging: atomisp_fops: Clean up tests if NULL returned on failure
Some functions like kmalloc/kzalloc return NULL on failure.
When NULL represents failure, !x is commonly used.
This was done using Coccinelle:
@@
expression *e;
identifier l1;
@@
e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...);
...
- e == NULL
+ !e
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'samples')
0 files changed, 0 insertions, 0 deletions