path: root/src/plugins/platforms
diff options
authorFlorian Bruhin <>2018-09-12 10:04:39 +0200
committerFlorian Bruhin <>2018-09-13 18:18:47 +0000
commit49efea26a5fae8c2275999c36c7c8d24cf4125de (patch)
tree88a829c298dc72a5938e0ec7c51b62877375dd22 /src/plugins/platforms
parent45c1473847ad65c4d43f9a605a86439867442883 (diff)
sqlite: Fix QSqlError handling when opening/closing database
Both sqlite3_open_v2 and sqlite3_close are documented to return an error code: However, those were ignored (other than checking whether the operation succeeded), causing QSqlError::nativeErrorCode() to always be "-1" when there was an error while opening/closing the database. Additionally, the error string needs to be read (via sqlite3_errmsg16) in qMakeError *before* d->access is set to 0, or the databaseText() will always be "out of memory" no matter what error actually happened. Task-number: QTBUG-70506 Change-Id: I75cbf178c9711442e640afd26c4502214d20c598 Reviewed-by: Andy Shaw <> Reviewed-by: Simon Hausmann <> Reviewed-by: Edward Welbourne <>
Diffstat (limited to 'src/plugins/platforms')
0 files changed, 0 insertions, 0 deletions