cosmetic fix of src/ac.c
authorNIIBE Yutaka <gniibe@fsij.org>
Tue, 1 Nov 2011 02:39:47 +0000 (11:39 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Tue, 1 Nov 2011 02:39:47 +0000 (11:39 +0900)
ChangeLog
src/ac.c

index 1442404..10057a9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2011-11-01  Niibe Yutaka  <gniibe@fsij.org>
 
+       * src/ac.c (calc_md): Fix comparison.
+
        * src/call-rsa.c (RSA_SIGNATURE_LENGTH): Use KEY_CONTENT_LEN.
        (rsa_sign, rsa_decrypt): Likewise.
        (modulus_calc): Don't assume it's 2048-bit.
index 4d29ef7..9994ff9 100644 (file)
--- a/src/ac.c
+++ b/src/ac.c
@@ -172,7 +172,7 @@ calc_md (int count, const uint8_t *salt, const uint8_t *pw, int pw_len,
       count -= pw_len + 8;
     }
 
-  if (count < 8)
+  if (count <= 8)
     sha1_update (&sha1_ctx, salt, count);
   else
     {