Fixed testrunner

This commit is contained in:
Daniel Marjamäki 2018-11-03 18:59:55 +01:00
parent 66ca03fa0c
commit fb76ef1db1
1 changed files with 1 additions and 1 deletions

View File

@ -599,7 +599,7 @@ void CheckAutoVariables::errorReturnTempReference(const Token *tok)
void CheckAutoVariables::errorInvalidDeallocation(const Token *tok, const ValueFlow::Value *val)
{
const Variable *var = val ? val->tokvalue->variable() : tok->variable();
const Variable *var = val ? val->tokvalue->variable() : (tok ? tok->variable() : nullptr);
std::string type = "auto-variable";
if (var) {