Changeset 2998 for pjproject/trunk/pjlib/src/pj/ssl_sock_symbian.cpp
- Timestamp:
- Nov 9, 2009 8:51:34 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib/src/pj/ssl_sock_symbian.cpp
r2990 r2998 98 98 }; 99 99 100 static CPjSSLSocket *NewL(const TDesC8 &ssl_proto) { 101 CPjSSLSocket *self = new (ELeave) CPjSSLSocket(); 100 static CPjSSLSocket *NewL(const TDesC8 &ssl_proto, 101 pj_qos_type qos_type, 102 const pj_qos_params &qos_params) 103 { 104 CPjSSLSocket *self = new (ELeave) CPjSSLSocket(qos_type, qos_params); 102 105 CleanupStack::PushL(self); 103 106 self->ConstructL(ssl_proto); … … 131 134 CSecureSocket *securesock_; 132 135 bool is_connected_; 136 137 pj_qos_type qos_type_; 138 pj_qos_params qos_params_; 139 133 140 CPjSSLSocketReader *reader_; 134 141 TBuf<32> ssl_proto_; … … 144 151 void RunL(); 145 152 146 CPjSSLSocket( ) :153 CPjSSLSocket(pj_qos_type qos_type, const pj_qos_params &qos_params) : 147 154 CActive(0), state_(SSL_STATE_NULL), sock_(PJ_INVALID_SOCKET), 148 securesock_(NULL), 149 is_connected_(false), reader_(NULL),150 cb_(NULL), key_(NULL)155 securesock_(NULL), is_connected_(false), 156 qos_type_(qos_type), qos_params_(qos_params), 157 reader_(NULL), cb_(NULL), key_(NULL) 151 158 {} 152 159 … … 165 172 } 166 173 if (sock_ != PJ_INVALID_SOCKET) { 167 delete (CPjSocket*)sock_;174 pj_sock_close(sock_); 168 175 sock_ = PJ_INVALID_SOCKET; 169 176 } … … 184 191 return status; 185 192 193 // Apply QoS 194 status = pj_sock_apply_qos2(sock_, qos_type_, &qos_params_, 195 2, THIS_FILE, NULL); 196 186 197 RSocket &rSock = ((CPjSocket*)sock_)->Socket(); 187 198 … … 412 423 pj_sockaddr local_addr; 413 424 pj_sockaddr rem_addr; 425 426 /* QoS settings */ 427 pj_qos_type qos_type; 428 pj_qos_params qos_params; 429 pj_bool_t qos_ignore_error; 430 414 431 415 432 pj_ssl_sock_proto proto; … … 502 519 } 503 520 pj_strdup_with_null(pool, &ssock->servername, ¶m->server_name); 521 522 ssock->qos_type = param->qos_type; 523 ssock->qos_ignore_error = param->qos_ignore_error; 524 pj_memcpy(&ssock->qos_params, ¶m->qos_params, 525 sizeof(param->qos_params)); 504 526 505 527 /* Finally */ … … 1062 1084 1063 1085 /* Init SSL engine */ 1064 TRAPD(err, sock = CPjSSLSocket::NewL(proto)); 1086 TRAPD(err, sock = CPjSSLSocket::NewL(proto, ssock->qos_type, 1087 ssock->qos_params)); 1065 1088 if (err != KErrNone) 1066 1089 return PJ_ENOMEM;
Note: See TracChangeset
for help on using the changeset viewer.