diff options
author | Marc Hoersken <info@marc-hoersken.de> | 2015-04-26 17:59:01 +0200 |
---|---|---|
committer | Marc Hoersken <info@marc-hoersken.de> | 2015-04-26 17:59:01 +0200 |
commit | 9a91e8059bbfcc80cb6fd5b980a4c6337c688a71 (patch) | |
tree | 4569e8da49040046404370d1e5658e524f08908b | |
parent | 3447c973d094dcd3cb578b099f6bf56f9ac2f407 (diff) |
schannel.c: Fix possible SEC_E_BUFFER_TOO_SMALL error
Reported-by: Brian Chrisman
-rw-r--r-- | lib/vtls/schannel.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/vtls/schannel.c b/lib/vtls/schannel.c index e9f455e44..7d25fd7d0 100644 --- a/lib/vtls/schannel.c +++ b/lib/vtls/schannel.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 2012 - 2014, Marc Hoersken, <info@marc-hoersken.de> + * Copyright (C) 2012 - 2015, Marc Hoersken, <info@marc-hoersken.de> * Copyright (C) 2012, Mark Salisbury, <mark.salisbury@hp.com> * Copyright (C) 2012 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al. * @@ -368,7 +368,8 @@ schannel_connect_step2(struct connectdata *conn, int sockindex) /* setup output buffers */ InitSecBuffer(&outbuf[0], SECBUFFER_TOKEN, NULL, 0); InitSecBuffer(&outbuf[1], SECBUFFER_ALERT, NULL, 0); - InitSecBufferDesc(&outbuf_desc, outbuf, 2); + InitSecBuffer(&outbuf[2], SECBUFFER_EMPTY, NULL, 0); + InitSecBufferDesc(&outbuf_desc, outbuf, 3); if(inbuf[0].pvBuffer == NULL) { failf(data, "schannel: unable to allocate memory"); |