Free all the sm_states at the end of each function.
commit7f2f6f04950dbe3b74a0684d2982aa443f5a326e
authorDan Carpenter <error27@gmail.com>
Mon, 2 Mar 2009 08:27:07 +0000 (2 11:27 +0300)
committerDan Carpenter <error27@gmail.com>
Mon, 2 Mar 2009 08:27:07 +0000 (2 11:27 +0300)
tree579c69d6112990cfbc8192aba5a83aa330168172
parenteb9248f96b35831938e781f95981ad9bbc8836b1
Free all the sm_states at the end of each function.

Most people probably think that it would be better to pay careful
attention to memory allocations and free them as you go along in
an organized way.  It turns out that method is hard to do.

I had to fix how the ->possible states were stored to avoid some
double frees and use after frees.

There are still lots of leaks of state_lists.

Also there is still a bug that triggers the OOM killer...

Signed-off-by: Dan Carpenter <error27@gmail.com>
smatch_slist.c
smatch_slist.h
smatch_states.c