diff options
author | Lasse Holmstedt <lasse.holmstedt@nokia.com> | 2010-08-27 11:05:25 (GMT) |
---|---|---|
committer | Lasse Holmstedt <lasse.holmstedt@nokia.com> | 2010-08-27 11:07:46 (GMT) |
commit | bd521ed56f8e4be7117dc3534c6fded68f7a70c5 (patch) | |
tree | f37a771048ad9214b4d8474dd07e3f815241d044 /src | |
parent | 7f69818e7dcd5b029010e5f930abed519956a8ff (diff) | |
download | Qt-bd521ed56f8e4be7117dc3534c6fded68f7a70c5.zip Qt-bd521ed56f8e4be7117dc3534c6fded68f7a70c5.tar.gz Qt-bd521ed56f8e4be7117dc3534c6fded68f7a70c5.tar.bz2 |
QDeclarativeDebug: Destroy incoming connections if already connected
Without this, QML Inspector in Qt Creator gets no error message for
failed connections, which can lead to confusion.
Reviewed-by: ogoffart
Diffstat (limited to 'src')
-rw-r--r-- | src/declarative/debugger/qdeclarativedebugservice.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/declarative/debugger/qdeclarativedebugservice.cpp b/src/declarative/debugger/qdeclarativedebugservice.cpp index dca2695..1bbfcf4 100644 --- a/src/declarative/debugger/qdeclarativedebugservice.cpp +++ b/src/declarative/debugger/qdeclarativedebugservice.cpp @@ -128,6 +128,8 @@ void QDeclarativeDebugServer::newConnection() if (d->connection) { qWarning("QDeclarativeDebugServer error: another client is already connected"); + QTcpSocket *faultyConnection = d->tcpServer->nextPendingConnection(); + delete faultyConnection; return; } |