From 23f47f82a6172027635de7c8a0192cbbf9c67f33 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Wed, 27 Jun 2012 05:11:21 +0200 Subject: [PATCH] * Retry on this sql error, too. --- src/libtomahawk/database/TomahawkSqlQuery.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libtomahawk/database/TomahawkSqlQuery.cpp b/src/libtomahawk/database/TomahawkSqlQuery.cpp index 1c2449993..4663023d4 100644 --- a/src/libtomahawk/database/TomahawkSqlQuery.cpp +++ b/src/libtomahawk/database/TomahawkSqlQuery.cpp @@ -84,7 +84,8 @@ TomahawkSqlQuery::exec() unsigned int retries = 0; while ( !QSqlQuery::exec() && ++retries < 10 ) { - if ( lastError().text().toLower().contains( "no query" ) ) + if ( lastError().text().toLower().contains( "no query" ) || + lastError().text().toLower().contains( "parameter count mismatch" ) ) { tDebug() << Q_FUNC_INFO << "Re-preparing query!";