diff options
| author | Julien Brunel <[email protected]> | 2008-10-10 19:00:19 +0000 |
|---|---|---|
| committer | Roland Dreier <[email protected]> | 2008-10-10 19:00:19 +0000 |
| commit | 6aea938f54ca785ce3bea67a8948698225c6ca58 (patch) | |
| tree | 0073e089b5c10a5baf116f4978480259c366ec89 /lib/bitmap.c | |
| parent | Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 (diff) | |
| download | kernel-6aea938f54ca785ce3bea67a8948698225c6ca58.tar.gz kernel-6aea938f54ca785ce3bea67a8948698225c6ca58.zip | |
RDMA/ucma: Test ucma_alloc_multicast() return against NULL, not with IS_ERR()
In case of error, the function ucma_alloc_multicast() returns a NULL
pointer, but never returns an ERR pointer. So after a call to this
function, an IS_ERR test should be replaced by a NULL test.
The semantic match that finds this problem is as follows:
(http://www.emn.fr/x-info/coccinelle/)
// <smpl>
@match bad_is_err_test@
expression x, E;
@@
x = ucma_alloc_multicast(...)
... when != x = E
IS_ERR(x)
// </smpl>
Signed-off-by: Julien Brunel <[email protected]>
Signed-off-by: Julia Lawall <[email protected]>
Signed-off-by: Roland Dreier <[email protected]>
Diffstat (limited to 'lib/bitmap.c')
0 files changed, 0 insertions, 0 deletions
