container_of: fix a bug in get_shared_cnt()
commit195efb8318c0513f87df81388eccbf3f0911ed56
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 24 Aug 2018 10:53:29 +0000 (24 13:53 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Fri, 24 Aug 2018 10:53:29 +0000 (24 13:53 +0300)
tree842d193d7c9f666b78840bd6a7dad98315c8fbe2
parent4249ed27127a7a5477206aa28109d56e08848a8c
container_of: fix a bug in get_shared_cnt()

The get_shared_cnt() is supposed to take a function pointer such as
foo->bar->func() and a parameter foo->bar->x and say that they have
"foo->bar" shared in common.  The bug is that it was taking a function
like "foo_bar()" and a parameter like "foo_param" and saying that they
have "foo_" in common.  When actually they're not related at all except
by chance that their names start with the same letters.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch_container_of.c