Ensure s_client and s_server work when read_ahead is set
[openssl.git] / apps / s_server.c
index 22e917542b3a5d673c681912d601cdbb153c9230..6e1c5989c5865eb2962f99d8735570be01b86b8b 100644 (file)
@@ -2213,7 +2213,7 @@ static int sv_body(int s, int stype, unsigned char *context)
         int read_from_sslcon;
 
         read_from_terminal = 0;
-        read_from_sslcon = SSL_pending(con)
+        read_from_sslcon = SSL_has_pending(con)
                            || (async && SSL_waiting_for_async(con));
 
         if (!read_from_sslcon) {
@@ -2451,7 +2451,7 @@ static int sv_body(int s, int stype, unsigned char *context)
                     ascii2ebcdic(buf, buf, i);
 #endif
                     raw_write_stdout(buf, (unsigned int)i);
-                    if (SSL_pending(con))
+                    if (SSL_has_pending(con))
                         goto again;
                     break;
                 case SSL_ERROR_WANT_ASYNC: