summaryrefslogtreecommitdiff
path: root/pjlib/src/pj/ioqueue_symbian.cpp
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2009-06-17 13:31:13 +0000
committerBenny Prijono <bennylp@teluu.com>2009-06-17 13:31:13 +0000
commit6e6537f83260a1d4e976ea77e2803e1a2d3cf115 (patch)
tree7e99f679a1488a58ba877b3fbf70f516057417d3 /pjlib/src/pj/ioqueue_symbian.cpp
parent667d03f95abda64795c2064630cef48f843062f7 (diff)
Ticket #758 (Problem with TCP transport on Symbian)
- fixed TCP recv() to use RecvOneOrMore() - fixed activesock unit test in pjlib-test git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2771 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/src/pj/ioqueue_symbian.cpp')
-rw-r--r--pjlib/src/pj/ioqueue_symbian.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/pjlib/src/pj/ioqueue_symbian.cpp b/pjlib/src/pj/ioqueue_symbian.cpp
index ee6d7e0d..d8e3aeeb 100644
--- a/pjlib/src/pj/ioqueue_symbian.cpp
+++ b/pjlib/src/pj/ioqueue_symbian.cpp
@@ -213,7 +213,16 @@ pj_status_t CIoqueueCallback::StartRead(pj_ioqueue_op_key_t *op_key,
} else {
aAddress_.SetAddress(0);
aAddress_.SetPort(0);
- sock_->Socket().Recv(aBufferPtr_, flags, iStatus);
+
+ if (sock_->IsDatagram()) {
+ sock_->Socket().Recv(aBufferPtr_, flags, iStatus);
+ } else {
+ // Using static like this is not pretty, but we don't need to use
+ // the value anyway, hence doing it like this is probably most
+ // optimal.
+ static TSockXfrLength len;
+ sock_->Socket().RecvOneOrMore(aBufferPtr_, flags, iStatus, len);
+ }
}
SetActive();
@@ -277,6 +286,7 @@ void CIoqueueCallback::HandleReadCompletion()
CPjSocket *CIoqueueCallback::HandleAcceptCompletion()
{
CPjSocket *pjNewSock = new CPjSocket(get_pj_socket()->GetAf(),
+ get_pj_socket()->GetSockType(),
blank_sock_);
int addrlen = 0;