summaryrefslogtreecommitdiffstats
path: root/src/sql
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@digia.com>2012-11-26 16:44:26 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-26 21:23:15 +0100
commit85cf6cd5f253694ad0e7d51fdd0fcfdfe65d8dc8 (patch)
treea384a2b10795840c90af600458072377828068cb /src/sql
parentfea68274b89a9bcde55eabbf6eb7bf2e8376d930 (diff)
tr()-Fix: Do not add up translateable strings.
Placeholders might go to a different position in translated strings. Change-Id: Id6a84ea931dc0487bd72eb8d01669369a3dce9c6 Reviewed-by: Caroline Chao <caroline.chao@digia.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Diffstat (limited to 'src/sql')
-rw-r--r--src/sql/drivers/mysql/qsql_mysql.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/sql/drivers/mysql/qsql_mysql.cpp b/src/sql/drivers/mysql/qsql_mysql.cpp
index 6a5d67f80b..e7b86cec42 100644
--- a/src/sql/drivers/mysql/qsql_mysql.cpp
+++ b/src/sql/drivers/mysql/qsql_mysql.cpp
@@ -1282,8 +1282,7 @@ bool QMYSQLDriver::open(const QString& db,
optionFlags))
{
if (!db.isEmpty() && mysql_select_db(d->mysql, db.toLocal8Bit().constData())) {
- setLastError(qMakeError(tr("Unable to open database '") + db +
- QLatin1Char('\''), QSqlError::ConnectionError, d));
+ setLastError(qMakeError(tr("Unable to open database '%1'").arg(db), QSqlError::ConnectionError, d));
mysql_close(d->mysql);
setOpenError(true);
return false;