Add lots of checks for memory allocation failure, error codes to indicate
[openssl.git] / crypto / asn1 / a_enum.c
index 49f9e994be4eb48ee1ae6d18892fe0bb17e08bef..af9fb9b39e318a2478fdfcde2fe2cd8a4696d0a0 100644 (file)
@@ -158,7 +158,7 @@ ASN1_ENUMERATED *BN_to_ASN1_ENUMERATED(BIGNUM *bn, ASN1_ENUMERATED *ai)
                unsigned char *new_data=OPENSSL_realloc(ret->data, len+4);
                if (!new_data)
                        {
-                       ASN1err(ASN1_F_BN_TO_ASN1_INTEGER,ERR_R_MALLOC_FAILURE);
+                       ASN1err(ASN1_F_BN_TO_ASN1_ENUMERATED,ERR_R_MALLOC_FAILURE);
                        goto err;
                        }
                ret->data=new_data;