Trim SQL string before logging them

See issue #337
This commit is contained in:
Martin Kleusberg
2015-06-22 11:56:27 +02:00
parent d5164a0c64
commit 1870f85e99

View File

@@ -1065,6 +1065,9 @@ DBBrowserObject DBBrowserDB::getObjectByName(const QString& name) const
void DBBrowserDB::logSQL(QString statement, int msgtype)
{
// Remove any leading and trailing spaces, tabs, or line breaks first
statement = statement.trimmed();
// Replace binary log messages by a placeholder text instead of printing gibberish
for(int i=0;i<statement.size();i++)
{