qt5base-lts/tests/auto/sql/kernel/qsqldatabase
Andy Shaw 9b361f0e90 Return an invalid QSqlDatabase when accessing from another thread
QSqlDatabase objects can only be used in the thread that the connection
was opened for. So if the driver was created already then we check if
the thread is correct. If it is not then we output a warning and return
an invalid QSqlDatabase.

[ChangeLog][QtSql][QSqlDatabase] QSqlDatabase::database() will return
an invalid QSqlDatabase if the calling thread does not own the requested
QSqlDatabase.

Task-number: QTBUG-216
Change-Id: Ib5a25aa62129e3925f9819109af05961e5178bc5
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-01-02 08:49:40 +00:00
..
testdata Remove exec bits from files that should not be executable 2015-06-07 22:50:19 +00:00
.gitignore Moved sql autotests into new directory structure 2011-09-06 09:32:15 +02:00
qsqldatabase.pro QSql tests: Remove Windows CE and clean up code. 2016-03-10 15:07:02 +00:00
tst_databases.h QSql tests: Remove Windows CE and clean up code. 2016-03-10 15:07:02 +00:00
tst_qsqldatabase.cpp Return an invalid QSqlDatabase when accessing from another thread 2018-01-02 08:49:40 +00:00