[PATCH] Fix sha224sum panic by registering SHA224 hash name.

Krzysztof Halasa khc at pm.waw.pl
Thu Jun 7 09:03:15 EDT 2012


barebox:/ sha224sum
BUG: failure at commands/digest.c:40/do_digest()!

Signed-off-by: Krzysztof Hałasa <khc at pm.waw.pl>

diff --git a/crypto/sha2.c b/crypto/sha2.c
index 17303e6..3096efe 100644
--- a/crypto/sha2.c
+++ b/crypto/sha2.c
@@ -313,6 +313,7 @@ static int digest_sha224_init(struct digest *d)
 
 static struct sha2 m224 = {
 	.d = {
+		.name = "sha224",
 		.init = digest_sha224_init,
 		.update = digest_sha2_update,
 		.final = digest_sha2_final,

-- 
Krzysztof Halasa



More information about the barebox mailing list