From 6572f9820a346730d8ac5d4cb64aa3490f31ead2 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Fri, 22 Jun 2012 02:40:43 +0200 Subject: [PATCH] * Stop logging every query. --- src/libtomahawk/database/TomahawkSqlQuery.cpp | 5 ++--- src/libtomahawk/database/TomahawkSqlQuery.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/libtomahawk/database/TomahawkSqlQuery.cpp b/src/libtomahawk/database/TomahawkSqlQuery.cpp index 7e12b756c..67b274f91 100644 --- a/src/libtomahawk/database/TomahawkSqlQuery.cpp +++ b/src/libtomahawk/database/TomahawkSqlQuery.cpp @@ -69,7 +69,7 @@ TomahawkSqlQuery::exec() #endif if ( log ) tLog( LOGSQL ) << "TomahawkSqlQuery::exec running in thread " << QThread::currentThread(); - + QTime t; t.start(); @@ -88,10 +88,9 @@ TomahawkSqlQuery::exec() showError(); int e = t.elapsed(); - if ( log || e >= QUERY_THRESHOLD ) tLog( LOGSQL ) << "TomahawkSqlQuery::exec (" << t.elapsed() << "ms ):" << lastQuery(); - + return ret; } diff --git a/src/libtomahawk/database/TomahawkSqlQuery.h b/src/libtomahawk/database/TomahawkSqlQuery.h index 3a77bceb9..4695e33bf 100644 --- a/src/libtomahawk/database/TomahawkSqlQuery.h +++ b/src/libtomahawk/database/TomahawkSqlQuery.h @@ -24,7 +24,7 @@ #include #include -#define TOMAHAWK_QUERY_ANALYZE 1 +//#define TOMAHAWK_QUERY_ANALYZE 1 class TomahawkSqlQuery : public QSqlQuery {