summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorWarwick Allison <warwick.allison@nokia.com>2009-11-04 03:58:28 (GMT)
committerWarwick Allison <warwick.allison@nokia.com>2009-11-04 03:58:28 (GMT)
commitbe71186962db5974113e89b0e7c7aa1ab3987379 (patch)
tree4ea4ed9124585c9521b395082359df6113e5541e /src
parent714f255d1da79c8824531fdea580d2ad7364e00b (diff)
parente2ecd43f569f172909fdd3e02fe3c1b70b02fc9e (diff)
downloadQt-be71186962db5974113e89b0e7c7aa1ab3987379.zip
Qt-be71186962db5974113e89b0e7c7aa1ab3987379.tar.gz
Qt-be71186962db5974113e89b0e7c7aa1ab3987379.tar.bz2
Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6
Diffstat (limited to 'src')
-rw-r--r--src/gui/s60framework/qs60mainappui.cpp2
-rw-r--r--src/sql/drivers/tds/qsql_tds.cpp21
2 files changed, 17 insertions, 6 deletions
diff --git a/src/gui/s60framework/qs60mainappui.cpp b/src/gui/s60framework/qs60mainappui.cpp
index 4ad78f9..4c4c994 100644
--- a/src/gui/s60framework/qs60mainappui.cpp
+++ b/src/gui/s60framework/qs60mainappui.cpp
@@ -163,7 +163,7 @@ void QS60MainAppUi::HandleResourceChangeL(TInt type)
/*!
* \brief Handles raw window server events.
*
- * The event type and information is passed in \a event, while the receiving control is passed in
+ * The event type and information is passed in \a wsEvent, while the receiving control is passed in
* \a destination.
*
* If you override this function, you should call the base class implementation if you do not
diff --git a/src/sql/drivers/tds/qsql_tds.cpp b/src/sql/drivers/tds/qsql_tds.cpp
index 2508833..ca1502c 100644
--- a/src/sql/drivers/tds/qsql_tds.cpp
+++ b/src/sql/drivers/tds/qsql_tds.cpp
@@ -164,13 +164,13 @@ Q_GLOBAL_STATIC(QTDSErrorHash, errs)
extern "C" {
static int CS_PUBLIC qTdsMsgHandler (DBPROCESS* dbproc,
- DBINT /*msgno*/,
+ DBINT msgno,
int msgstate,
int severity,
char* msgtext,
- char* /*srvname*/,
+ char* srvname,
char* /*procname*/,
- int /*line*/)
+ int line)
{
QTDSResultPrivate* p = errs()->value(dbproc);
@@ -181,9 +181,20 @@ static int CS_PUBLIC qTdsMsgHandler (DBPROCESS* dbproc,
}
if (severity > 0) {
- QString errMsg = QString::fromLatin1("%1 (%2)").arg(QString::fromAscii(msgtext)).arg(
- msgstate);
+ QString errMsg = QString::fromLatin1("%1 (Msg %2, Level %3, State %4, Server %5, Line %6)")
+ .arg(QString::fromAscii(msgtext))
+ .arg(msgno)
+ .arg(severity)
+ .arg(msgstate)
+ .arg(QString::fromAscii(srvname))
+ .arg(line);
p->addErrorMsg(errMsg);
+ if (severity > 10) {
+ // Severe messages are really errors in the sense of lastError
+ errMsg = p->getErrorMsgs();
+ p->lastError = qMakeError(errMsg, QSqlError::UnknownError, msgno);
+ p->clearErrorMsgs();
+ }
}
return INT_CANCEL;