aboutsummaryrefslogtreecommitdiffstats
path: root/src/declarative/debugger/qdebugmessageservice.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative/debugger/qdebugmessageservice.cpp')
-rw-r--r--src/declarative/debugger/qdebugmessageservice.cpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/declarative/debugger/qdebugmessageservice.cpp b/src/declarative/debugger/qdebugmessageservice.cpp
index 1604e3524b..4e92603bdd 100644
--- a/src/declarative/debugger/qdebugmessageservice.cpp
+++ b/src/declarative/debugger/qdebugmessageservice.cpp
@@ -1,8 +1,8 @@
/****************************************************************************
**
-** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
-** Contact: Nokia Corporation (qt-info@nokia.com)
+** Contact: http://www.qt-project.org/
**
** This file is part of the QtDeclarative module of the Qt Toolkit.
**
@@ -66,7 +66,7 @@ public:
QDebugMessageService::QDebugMessageService(QObject *parent) :
QDeclarativeDebugService(*(new QDebugMessageServicePrivate()),
- QLatin1String("DebugMessages"), 1, parent)
+ QLatin1String("DebugMessages"), 2, parent)
{
Q_D(QDebugMessageService);
@@ -89,13 +89,9 @@ void QDebugMessageService::sendDebugMessage(QtMsgType type, const char *buf)
//We do not want to alter the message handling mechanism
//We just eavesdrop and forward the messages to a port
//only if a client is connected to it.
- QByteArray debugMessage;
- QDataStream rs(&debugMessage, QIODevice::WriteOnly);
- rs << type << QString::fromLocal8Bit(buf).toUtf8();
-
QByteArray message;
QDataStream ws(&message, QIODevice::WriteOnly);
- ws << QByteArray("MESSAGE") << debugMessage;
+ ws << QByteArray("MESSAGE") << type << QString::fromLocal8Bit(buf).toUtf8();
sendMessage(message);
if (d->oldMsgHandler)