}
}
+/*
+ * Return values are as per SSL_read(), i.e.
+ * >0 The number of read bytes
+ * 0 Failure (not retryable)
+ * <0 Failure (may be retryable)
+ */
int ssl3_read_n(SSL *s, int n, int max, int extend, int clearold)
{
/*
if (s->mode & SSL_MODE_RELEASE_BUFFERS && !SSL_IS_DTLS(s))
if (len + left == 0)
ssl3_release_read_buffer(s);
- return (i);
+ return -1;
}
left += i;
/*
return -1;
}
-/* if s->s3->wbuf.left != 0, we need to call this */
+/* if s->s3->wbuf.left != 0, we need to call this
+ *
+ * Return values are as per SSL_read(), i.e.
+ * >0 The number of read bytes
+ * 0 Failure (not retryable)
+ * <0 Failure (may be retryable)
+ */
int ssl3_write_pending(SSL *s, int type, const unsigned char *buf,
unsigned int len)
{
*/
SSL3_BUFFER_set_left(&wb[currbuf], 0);
}
- return (i);
+ return -1;
}
SSL3_BUFFER_add_offset(&wb[currbuf], i);
SSL3_BUFFER_add_left(&wb[currbuf], -i);