Code Review
/
common
/
thrift.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
0e8e609
)
THRIFT-587. cpp: Properly set addrLen before accept calls
author
David Reiss
<dreiss@apache.org>
Sat, 19 Sep 2009 01:59:13 +0000
(
01:59
+0000)
committer
David Reiss
<dreiss@apache.org>
Sat, 19 Sep 2009 01:59:13 +0000
(
01:59
+0000)
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@816850
13f79535
-47bb-0310-9956-
ffa450edef68
lib/cpp/src/server/TNonblockingServer.cpp
patch
|
blob
|
history
diff --git
a/lib/cpp/src/server/TNonblockingServer.cpp
b/lib/cpp/src/server/TNonblockingServer.cpp
index
45f635c
..
32f021a
100644
(file)
--- a/
lib/cpp/src/server/TNonblockingServer.cpp
+++ b/
lib/cpp/src/server/TNonblockingServer.cpp
@@
-591,6
+591,9
@@
void TNonblockingServer::handleEvent(int fd, short which) {
// Put this client connection into the proper state
clientConnection->transition();
+
+ // addrLen is written by the accept() call, so needs to be set before the next call.
+ addrLen = sizeof(addr);
}
// Done looping accept, now we have to make sure the error is due to