function_ptrs: record local pointer scope correctly
commitbd9de9798748b9fbbed6b58c1188871bd43acbae
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 14 May 2018 11:40:38 +0000 (14 14:40 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Mon, 14 May 2018 11:40:38 +0000 (14 14:40 +0300)
tree3665732b61ab86c638749c0b4e1f4593520280e8
parent9783dbbf88a0b2c5d941649c1a248b8cd2026a8a
function_ptrs: record local pointer scope correctly

Say you have a function pointer that's local to a specific function, then
that's supposed to be recorded as "function_name pointer_name".  But the
is_local_symbol() function always returned false so everything was treated
as global.

And then because there are a bunch of function pointer called "func", it
meant they were all mixed together.  Which was a mess because it meant
that about a 100 functions were called with too much data and we just
threw it all away.  And probably there were some function which were called
with not such common pointer names and so it was mixed with invalid data.

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