string_list: prevent a use after free
commit9e15f16aaa5a7a2fae1f43191fbdafbf9274df4b
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 8 Jan 2018 22:03:26 +0000 (9 01:03 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Mon, 8 Jan 2018 22:07:19 +0000 (9 01:07 +0300)
treee7f9ec3f3d8b78d04d5be6ce06fb60246893092b
parent072931a321eefdda2a7059d7a934c8bc014fd8c9
string_list: prevent a use after free

We need to allocate a new string here...  It's surprising this doesn't
show up more in testing.  The thing is that probably because it isn't
really freed, it's just re-used then it means we can't find the original
string in the list any more.

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