>> I would like to detect that a corresponding null pointer check would be 
>> missing
>> (before the data can be used for further data processing).
>
> * x = kmemdup(...);
>   ... when != x
> (
>   x->f
> |
>   f(...,<+...x...+>,...)
> )

This analysis approach looks promising in principle. I needed another moment
to become aware that it indicates pointer usage requirements
which can occasionally not be met (like in the mentioned function 
“imx_pd_bind”).
If the expression “x” would be split into accesses to data structure members,
the data processing can probably result in another desirable information 
display.

The pointer usages vary in affected function implementations (as usual).

Regards,
Markus
_______________________________________________
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to