From be4d3f53f3a45b4c7f247fe65c14e87c50d6be13 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Wed, 20 Feb 2013 14:58:27 +0300 Subject: [PATCH] returns: add a check for __inline_fn This should ignore returns from inline functions. Signed-off-by: Dan Carpenter --- smatch_returns.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/smatch_returns.c b/smatch_returns.c index c2f6c30a..436af9d8 100644 --- a/smatch_returns.c +++ b/smatch_returns.c @@ -40,11 +40,15 @@ static void call_hooks() static void match_return(struct expression *ret_value) { + if (__inline_fn) + return; merge_slist(&all_return_states, __get_cur_slist()); } static void match_end_func(struct symbol *sym) { + if (__inline_fn) + return; merge_slist(&all_return_states, __get_cur_slist()); call_hooks(); free_slist(&all_return_states); -- 2.11.4.GIT