report a more useful error than undefined when trying to use HashSHA256 in SSL3 mode.

This commit is contained in:
Vincent Hanquez 2013-11-29 17:00:09 +08:00
parent 9883b8644f
commit e5e96fb157

View file

@ -73,7 +73,7 @@ instance HashCtxC HashSHA256 where
hashCName _ = "SHA256"
hashCInit _ = HashSHA256 SHA256.init
hashCUpdate (HashSHA256 ctx) b = HashSHA256 (SHA256.update ctx b)
hashCUpdateSSL _ _ = undefined
hashCUpdateSSL _ _ = error "CUpdateSSL with HashSHA256"
hashCFinal (HashSHA256 ctx) = SHA256.finalize ctx
-- functions to use the hidden class.