diff --git a/qa/coccinelle/malloc-error-check.cocci b/qa/coccinelle/malloc-error-check.cocci index b245189a23..96c09f0b85 100644 --- a/qa/coccinelle/malloc-error-check.cocci +++ b/qa/coccinelle/malloc-error-check.cocci @@ -52,6 +52,12 @@ if (x != NULL) S1 else S2 if (x && E1) S1 | BUG_ON(x == NULL) +| +FAIL_IF(x == NULL) +| +FAIL_IF(unlikely(x == NULL)) +| +FAIL_IF_NULL(x) )