Fixed #2951 (Small code factorization in checkmemoryleak.cpp)
This commit is contained in:
parent
c00a1526bd
commit
50f78ce329
|
@ -2887,9 +2887,7 @@ void CheckMemoryLeakInClass::variable(const Scope *scope, const Token *tokVarnam
|
||||||
// Function call .. possible deallocation
|
// Function call .. possible deallocation
|
||||||
else if (Token::Match(tok->previous(), "[{};] %var% ("))
|
else if (Token::Match(tok->previous(), "[{};] %var% ("))
|
||||||
{
|
{
|
||||||
if (!std::bsearch(tok->str().c_str(), call_func_white_list,
|
if (!CheckMemoryLeakInFunction::test_white_list(tok->str().c_str()))
|
||||||
sizeof(call_func_white_list) / sizeof(call_func_white_list[0]),
|
|
||||||
sizeof(call_func_white_list[0]), call_func_white_list_compare))
|
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue