put the type of the handshake for the parsing of handshake message.

This commit is contained in:
Vincent Hanquez 2014-03-22 05:51:51 +00:00
parent 8088d3e265
commit 14c3325c75

View file

@ -173,7 +173,7 @@ decodeHandshakes b = runGetErr "handshakes" getAll b
else liftM ((:) x) getAll
decodeHandshake :: CurrentParams -> HandshakeType -> ByteString -> Either TLSError Handshake
decodeHandshake cp ty = runGetErr "handshake" $ case ty of
decodeHandshake cp ty = runGetErr ("handshake[" ++ show ty ++ "]") $ case ty of
HandshakeType_HelloRequest -> decodeHelloRequest
HandshakeType_ClientHello -> decodeClientHello
HandshakeType_ServerHello -> decodeServerHello