add ssl23_peek

This commit is contained in:
Bodo Möller
2001-03-08 21:53:29 +00:00
parent fac683684b
commit f46a878e3f
4 changed files with 34 additions and 16 deletions

View File

@@ -726,6 +726,12 @@ int SSL_read(SSL *s,char *buf,int num)
int SSL_peek(SSL *s,char *buf,int num)
{
if (s->handshake_func == 0)
{
SSLerr(SSL_F_SSL_READ, SSL_R_UNINITIALIZED);
return -1;
}
if (s->shutdown & SSL_RECEIVED_SHUTDOWN)
{
return(0);