1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-05 13:47:26 +02:00

* Safely handle unknown DB commands.

This commit is contained in:
Christian Muehlhaeuser
2011-01-14 17:07:30 +01:00
parent a4e140972e
commit 9c6e098841

View File

@@ -64,7 +64,7 @@ DatabaseWorker::doWork( QSharedPointer<DatabaseCommand> cmd )
if( cmd->doesMutates() ) if( cmd->doesMutates() )
{ {
bool transok = m_dbimpl->database().transaction(); bool transok = m_dbimpl->database().transaction();
Q_ASSERT( transok ); // Q_ASSERT( transok );
Q_UNUSED( transok ); Q_UNUSED( transok );
} }
try try
@@ -141,7 +141,7 @@ DatabaseWorker::doWork( QSharedPointer<DatabaseCommand> cmd )
if( cmd->doesMutates() ) if( cmd->doesMutates() )
m_dbimpl->database().rollback(); m_dbimpl->database().rollback();
Q_ASSERT( false ); // Q_ASSERT( false );
} }
catch(...) catch(...)
{ {