aboutsummaryrefslogtreecommitdiffstats
path: root/src/gnutls_io.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gnutls_io.c')
-rw-r--r--src/gnutls_io.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gnutls_io.c b/src/gnutls_io.c
index 753c87b..4f8e486 100644
--- a/src/gnutls_io.c
+++ b/src/gnutls_io.c
@@ -72,13 +72,13 @@ static int char_buffer_read(mgs_char_buffer_t * buffer, char *in,
72 72
73 if (buffer->length > inl) { 73 if (buffer->length > inl) {
74 /* we have have enough to fill the caller's buffer */ 74 /* we have have enough to fill the caller's buffer */
75 memcpy(in, buffer->value, inl); 75 memmove(in, buffer->value, inl);
76 buffer->value += inl; 76 buffer->value += inl;
77 buffer->length -= inl; 77 buffer->length -= inl;
78 } 78 }
79 else { 79 else {
80 /* swallow remainder of the buffer */ 80 /* swallow remainder of the buffer */
81 memcpy(in, buffer->value, buffer->length); 81 memmove(in, buffer->value, buffer->length);
82 inl = buffer->length; 82 inl = buffer->length;
83 buffer->value = NULL; 83 buffer->value = NULL;
84 buffer->length = 0; 84 buffer->length = 0;
@@ -353,7 +353,7 @@ static apr_status_t gnutls_io_input_getline(mgs_handle_t * ctxt,
353 return APR_SUCCESS; 353 return APR_SUCCESS;
354} 354}
355 355
356#define HANDSHAKE_MAX_TRIES 100 356#define HANDSHAKE_MAX_TRIES 1024
357static int gnutls_do_handshake(mgs_handle_t * ctxt) 357static int gnutls_do_handshake(mgs_handle_t * ctxt)
358{ 358{
359 int ret; 359 int ret;