last commit was wrong. Now it works. :)
[openssl.git] / crypto / bn / bn_lib.c
index af8ec34..658a491 100644 (file)
@@ -786,9 +786,9 @@ int bn_cmp_part_words(const BN_ULONG *a, const BN_ULONG *b,
 
        if (dl < 0)
                {
-               for (i=-dl; i<0; i++)
+               for (i=dl; i<0; i++)
                        {
-                       if (b[n+i] != 0)
+                       if (b[n-i] != 0)
                                return -1; /* a < b */
                        }
                }