Update TLSSession::checkDirection() doc

Make it clear that TLS_WANT_READ must be returned if underlying
SSL/TLS lib does not indicate I/O direction. This is because
SocketCore sets wantRead_ = true when TLS_WANT_READ is returned and
otherwise sets wantWrite_ = true. We only want to set wantWrite_ =
true iff we have some pending data to send.
pull/67/merge
Tatsuhiro Tsujikawa 2013-04-09 01:12:51 +09:00
parent 83b801a0a5
commit 15e1a79914
1 changed files with 2 additions and 2 deletions

View File

@ -79,8 +79,8 @@ public:
// Returns TLS_WANT_READ if SSL/TLS session needs more data from // Returns TLS_WANT_READ if SSL/TLS session needs more data from
// remote endpoint to proceed, or TLS_WANT_WRITE if SSL/TLS session // remote endpoint to proceed, or TLS_WANT_WRITE if SSL/TLS session
// needs to write more data to proceed. If SSL/TLS session needs // needs to write more data to proceed. If SSL/TLS session needs
// neither read nor write data at the moment, return value is // neither read nor write data at the moment, TLS_WANT_READ must be
// undefined. // returned.
virtual int checkDirection() = 0; virtual int checkDirection() = 0;
// Sends |data| with length |len|. This function returns the number // Sends |data| with length |len|. This function returns the number