aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2015-10-16 22:42:30 +0200
committerDaniel Stenberg <daniel@haxx.se>2015-10-16 22:42:56 +0200
commit443e81ea47bcb6e60903cf3954cfe907217f05e9 (patch)
tree74433d270af3d1f7e3f05647b22b4a8e5c45be62
parentc6aedf680f6923ffbe4dd4fd4e68e7dadcd5fb19 (diff)
multi: fix off-by-one finit[] array size
introduced in c6aedf680f6. It needs to be CURLM_STATE_LAST big since it must hande the range 0 .. CURLM_STATE_MSGSENT (18) and CURLM_STATE_LAST is 19 right now. Reported-by: Dan Fandrich Bug: http://curl.haxx.se/mail/lib-2015-10/0069.html
-rw-r--r--lib/multi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/multi.c b/lib/multi.c
index 12e84b9e5..14152be20 100644
--- a/lib/multi.c
+++ b/lib/multi.c
@@ -110,7 +110,7 @@ static void mstate(struct SessionHandle *data, CURLMstate state
)
{
CURLMstate oldstate = data->mstate;
- static const init_multistate_func finit[CURLM_STATE_LAST-1] = {
+ static const init_multistate_func finit[CURLM_STATE_LAST] = {
NULL,
NULL,
Curl_init_CONNECT, /* CONNECT */