DSA_verify() and DSA_sign() might return -1...
authorRichard Levitte <levitte@openssl.org>
Mon, 11 Sep 2000 22:21:38 +0000 (22:21 +0000)
committerRichard Levitte <levitte@openssl.org>
Mon, 11 Sep 2000 22:21:38 +0000 (22:21 +0000)
apps/speed.c

index dcb9bae..c468e33 100644 (file)
@@ -1210,7 +1210,7 @@ int MAIN(int argc, char **argv)
                        {
                        rsa_num=DSA_sign(EVP_PKEY_DSA,buf,20,buf2,
                                &kk,dsa_key[j]);
-                       if (rsa_num == 0)
+                       if (rsa_num <= 0)
                                {
                                BIO_printf(bio_err,"DSA sign failure\n");
                                ERR_print_errors(bio_err);
@@ -1233,7 +1233,7 @@ int MAIN(int argc, char **argv)
                        {
                        rsa_num2=DSA_verify(EVP_PKEY_DSA,buf,20,buf2,
                                kk,dsa_key[j]);
-                       if (rsa_num2 == 0)
+                       if (rsa_num2 <= 0)
                                {
                                BIO_printf(bio_err,"DSA verify failure\n");
                                ERR_print_errors(bio_err);