Minor optimization use QString midRef instead of mid.
It doesn't create a temporary string. Change-Id: If5c540422f69e573107d1f5a886ac7174ae99853 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
This commit is contained in:
parent
a6c79344f7
commit
3558c0cd74
@ -609,7 +609,7 @@ bool QSQLiteDriver::open(const QString & db, const QString &, const QString &, c
|
||||
foreach (const QString &option, opts) {
|
||||
if (option.startsWith(QLatin1String("QSQLITE_BUSY_TIMEOUT="))) {
|
||||
bool ok;
|
||||
const int nt = option.mid(21).toInt(&ok);
|
||||
const int nt = option.midRef(21).toInt(&ok);
|
||||
if (ok)
|
||||
timeOut = nt;
|
||||
} else if (option == QLatin1String("QSQLITE_OPEN_READONLY")) {
|
||||
|
Loading…
Reference in New Issue
Block a user