summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Liu <net147@gmail.com>2010-11-26 10:20:56 +0100
committerJoerg Bornemann <joerg.bornemann@nokia.com>2010-11-26 11:10:13 +0100
commit0bf8f70f85a24ab2864775bdd38f5ced43a7d4de (patch)
treea065683fe2abd91d4127f320d85140099dd56281
parent85f42777111060037476895ed08ded513d44a048 (diff)
QLocalSocket/Win: do not emit error() when no error actually occurred
This fixes a regression in 4d0c4b9f09b35d707d437611519d0024f6f87a8c. Previously the error string was set if the error is not ERROR_PIPE_NOT_CONNECTED but the commit changed this behaviour to set the error string if it is ERROR_PIPE_NOT_CONNECTED. Task-number: QTBUG-13646 Merge-request: 941 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
-rw-r--r--src/network/socket/qlocalsocket_win.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/socket/qlocalsocket_win.cpp b/src/network/socket/qlocalsocket_win.cpp
index 4907f2c9b3..6c3b769651 100644
--- a/src/network/socket/qlocalsocket_win.cpp
+++ b/src/network/socket/qlocalsocket_win.cpp
@@ -322,9 +322,9 @@ bool QLocalSocketPrivate::completeAsyncRead()
// buffer. We will read the remaining data in the next call.
break;
case ERROR_PIPE_NOT_CONNECTED:
- setErrorString(QLatin1String("QLocalSocketPrivate::completeAsyncRead"));
- // fall through
+ return false;
default:
+ setErrorString(QLatin1String("QLocalSocketPrivate::completeAsyncRead"));
return false;
}
}