Fix bug in psk_identity_hint parsing

This commit is contained in:
Manuel Pégourié-Gonnard 2013-10-15 11:55:33 +02:00
parent bac0e3b7d2
commit 59b9fe28f0

View file

@ -1161,7 +1161,7 @@ static int ssl_parse_server_psk_hint( ssl_context *ssl,
*
* opaque psk_identity_hint<0..2^16-1>;
*/
len = (*p)[1] << 8 | (*p)[0];
len = (*p)[0] << 8 | (*p)[1];
*p += 2;
if( (*p) + len > end )