Jim, I noticed that sha1.h is missing a SHA1_DIGEST_SIZE #define, which
can be useful in code using the sha1 package (such as the self test in
the previous post..).  md2, md4 and md5 have similar defines.  What do
you think about adding it to sha1.h?  I.e.:

2008-01-31  Simon Josefsson  <[EMAIL PROTECTED]>

        * lib/sha1.h (SHA1_DIGEST_SIZE): Add.

diff --git a/lib/sha1.h b/lib/sha1.h
index 9e55974..4ffda7a 100644
--- a/lib/sha1.h
+++ b/lib/sha1.h
@@ -23,6 +23,8 @@
 # include <stdio.h>
 # include <stdint.h>
 
+#define SHA1_DIGEST_SIZE 20
+
 /* Structure to save state of computation between the single steps.  */
 struct sha1_ctx
 {

/Simon


Reply via email to