add ssl23_peek

This commit is contained in:
Bodo Möller
2001-03-08 21:54:02 +00:00
parent 4ea3855514
commit 5451e0d924
4 changed files with 34 additions and 16 deletions

View File

@@ -784,6 +784,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);