Advance to the next state variant when reusing messages (PR3597).

(Imported from upstream's 7a04b854d655785798d471df25ffd5036f3cc46b.)

This does not affect BoringSSL as ssl3_get_client_hello advances to yet another
state immediately after reading the message. But the state advance is correct.
It matches the normal exit for this function.

Change-Id: I8a664f2ad5f80beacbaf3e17a7786a5c9e8ef30e
Reviewed-on: https://boringssl-review.googlesource.com/2480
Reviewed-by: Piotr Sikora <piotr@cloudflare.com>
Reviewed-by: Adam Langley <agl@google.com>
This commit is contained in:
David Benjamin 2014-12-04 16:38:48 -05:00 committed by Adam Langley
parent 0ac86b0220
commit 8c37cb60d4

View File

@ -367,6 +367,7 @@ long ssl3_get_message(SSL *s, int st1, int stn, int mt, long max, int hash_messa
goto f_err;
}
*ok=1;
s->state = stn;
s->init_msg = (uint8_t*)s->init_buf->data + 4;
s->init_num = (int)s->s3->tmp.message_size;
return s->init_num;