Remove unreachable code
The unknown types are treated as strings by default. Coverity-Id: 59489 Change-Id: Ib0eaf5c27d3afaf694c8a2acca42bef6808c8a9f Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This commit is contained in:
parent
7f12f94e48
commit
2005b9fae1
@ -699,10 +699,8 @@ QVariant QMYSQLResult::data(int field)
|
||||
}
|
||||
if(ok)
|
||||
return v;
|
||||
else
|
||||
return QVariant();
|
||||
return QVariant();
|
||||
}
|
||||
return QVariant(val.toDouble());
|
||||
case QVariant::Date:
|
||||
return qDateFromString(val);
|
||||
case QVariant::Time:
|
||||
@ -719,12 +717,11 @@ QVariant QMYSQLResult::data(int field)
|
||||
}
|
||||
return QVariant(ba);
|
||||
}
|
||||
default:
|
||||
case QVariant::String:
|
||||
default:
|
||||
return QVariant(val);
|
||||
}
|
||||
qWarning("QMYSQLResult::data: unknown data type");
|
||||
return QVariant();
|
||||
Q_UNREACHABLE();
|
||||
}
|
||||
|
||||
bool QMYSQLResult::isNull(int field)
|
||||
|
Loading…
Reference in New Issue
Block a user