Commit 1db1a100 authored by Karel Slaný's avatar Karel Slaný

Added a simple input check into SQLiteDb::openDb().

parent c8104762
......@@ -442,6 +442,10 @@ bool SQLiteDb::openDb(const QString &fileName, OpenFlags flags)
Q_ASSERT(0);
return false;
}
if (Q_UNLIKELY((!(flags & FORCE_IN_MEMORY)) && (fileName == memoryLocation))) {
Q_ASSERT(0);
return false;
}
if (m_db.isOpen()) {
m_db.close();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment