- ExtendedHandshakeMsg t b-> do putWord32be msgLen
- putWord8 20
- putWord8 t -- 0 => handshake msg
- -- actual extension msg follows
- mapM_ putWord8 blockList
- where blockList = unpack b
- blockLen = length blockList
-
+ ExtendedMsg t b-> do putWord32be (fromIntegral blockLen)
+ putWord8 20
+ putWord8 (fromIntegral t) -- 0 => handshake msg
+ -- actual extension msg follows
+ mapM_ putWord8 blockList
+ where blockList = unpack b
+ blockLen = length blockList