Avoid getting warnings about unary - being used on unsigned integer.
authorRichard Levitte <levitte@openssl.org>
Tue, 21 Nov 2000 23:29:55 +0000 (23:29 +0000)
committerRichard Levitte <levitte@openssl.org>
Tue, 21 Nov 2000 23:29:55 +0000 (23:29 +0000)
crypto/bn/bn_mul.c

index f730e5d..0227354 100644 (file)
@@ -106,22 +106,22 @@ BN_ULONG bn_sub_part_words(BN_ULONG *r,
                for (;;)
                        {
                        t = b[0];
-                       r[0] = (-t-c)&BN_MASK2;
+                       r[0] = (0-t-c)&BN_MASK2;
                        if (t != 0) c=1;
                        if (++dl >= 0) break;
 
                        t = b[1];
-                       r[1] = (-t-c)&BN_MASK2;
+                       r[1] = (0-t-c)&BN_MASK2;
                        if (t != 0) c=1;
                        if (++dl >= 0) break;
 
                        t = b[2];
-                       r[2] = (-t-c)&BN_MASK2;
+                       r[2] = (0-t-c)&BN_MASK2;
                        if (t != 0) c=1;
                        if (++dl >= 0) break;
 
                        t = b[3];
-                       r[3] = (-t-c)&BN_MASK2;
+                       r[3] = (0-t-c)&BN_MASK2;
                        if (t != 0) c=1;
                        if (++dl >= 0) break;