astIsFloat: Fix crash when there is no second operand for '.'

This commit is contained in:
Daniel Marjamäki 2014-08-17 14:28:31 +02:00
parent f7f44f24c7
commit ebc0b6cd44
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ namespace {
static bool astIsFloat(const Token *tok, bool unknown)
{
if (tok->str() == ".")
if (tok->astOperand2() && tok->str() == ".")
return astIsFloat(tok->astOperand2(), unknown);
if (tok->astOperand1() && tok->str() != "?" && astIsFloat(tok->astOperand1(),unknown))