Import of old SSLeay release: SSLeay 0.9.1b (unreleased)
[openssl.git] / crypto / asn1 / x_algor.c
index 0ed2c87b6494576b0a37527464a38c0762f3f4fc..01aa0cb6fc6e5866bb8ed4562352de16f78a7742 100644 (file)
@@ -61,9 +61,9 @@
 #include "asn1_mac.h"
 
 /*
- * ASN1err(ASN1_F_D2I_X509_ALGOR,ASN1_R_LENGTH_MISMATCH);
- * ASN1err(ASN1_F_X509_ALGOR_NEW,ASN1_R_EXPECTING_A_SEQUENCE);
- * ASN1err(ASN1_F_D2I_X509_ALGOR,ASN1_R_LENGTH_MISMATCH);
+ * ASN1err(ASN1_F_D2I_X509_ALGOR,ERR_R_ASN1_LENGTH_MISMATCH);
+ * ASN1err(ASN1_F_X509_ALGOR_NEW,ERR_R_EXPECTING_AN_ASN1_SEQUENCE);
+ * ASN1err(ASN1_F_D2I_X509_ALGOR,ERR_R_ASN1_LENGTH_MISMATCH);
  */
 
 int i2d_X509_ALGOR(a,pp)
@@ -107,9 +107,10 @@ long length;
 X509_ALGOR *X509_ALGOR_new()
        {
        X509_ALGOR *ret=NULL;
+       ASN1_CTX c;
 
        M_ASN1_New_Malloc(ret,X509_ALGOR);
-       M_ASN1_New(ret->algorithm,ASN1_OBJECT_new);
+       ret->algorithm=OBJ_nid2obj(NID_undef);
        ret->parameter=NULL;
        return(ret);
        M_ASN1_New_Error(ASN1_F_X509_ALGOR_NEW);