Comparing a pointer (data) with 0 using > is incorrect. The changed
[openssl.git] / crypto / ecdsa / ecs_asn1.c
index b3bdd4e5fbe9902d7ccce644519569d5c31c385c..542a987bc26e78814e95ae6824fb2b0a75ab8ff9 100644 (file)
@@ -439,7 +439,9 @@ ECDSA         *ECDSA_x9_62parameters2ecdsa(const X9_62_EC_PARAMETERS *params, EC
                if ((point = EC_POINT_new(ret->group)) == NULL) goto err;
        }
        else OPENSSL_ECDSA_ABORT(ECDSA_R_WRONG_FIELD_IDENTIFIER)
                if ((point = EC_POINT_new(ret->group)) == NULL) goto err;
        }
        else OPENSSL_ECDSA_ABORT(ECDSA_R_WRONG_FIELD_IDENTIFIER)
-       if (params->curve->seed != NULL && params->curve->seed->data > 0)
+       /* FIXME!!!  It seems like the comparison of data with 0 isn't the
+          intended thing. */
+       if (params->curve->seed != NULL && params->curve->seed->data != 0)
        {
                if (ret->seed != NULL)
                        OPENSSL_free(ret->seed);
        {
                if (ret->seed != NULL)
                        OPENSSL_free(ret->seed);