projects
/
oweals
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make sure we get the definition of OPENSSL_NO_BIO and OPENSSL_NO_RSA.
[oweals/openssl.git]
/
crypto
/
asn1
/
t_x509.c
diff --git
a/crypto/asn1/t_x509.c
b/crypto/asn1/t_x509.c
index ae6d5ce041863ba3cf8e0b93de1db6869d7bac9b..36cef4605db72e938c6ca5673339c40feec1cfc4 100644
(file)
--- a/
crypto/asn1/t_x509.c
+++ b/
crypto/asn1/t_x509.c
@@
-66,8
+66,8
@@
#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
#endif
#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
#endif
-#ifndef OPENSSL_NO_EC
DSA
-#include <openssl/ec
dsa
.h>
+#ifndef OPENSSL_NO_EC
+#include <openssl/ec.h>
#endif
#include <openssl/objects.h>
#include <openssl/x509.h>
#endif
#include <openssl/objects.h>
#include <openssl/x509.h>
@@
-232,11
+232,11
@@
int X509_print_ex(BIO *bp, X509 *x, unsigned long nmflags, unsigned long cflag)
}
else
#endif
}
else
#endif
-#ifndef OPENSSL_NO_EC
DSA
- if (pkey->type == EVP_PKEY_EC
DSA
)
+#ifndef OPENSSL_NO_EC
+ if (pkey->type == EVP_PKEY_EC)
{
{
- BIO_printf(bp, "%12sEC
DSA
Public Key:\n","");
- EC
DSA_print(bp, pkey->pkey.ecdsa
, 16);
+ BIO_printf(bp, "%12sEC Public Key:\n","");
+ EC
_KEY_print(bp, pkey->pkey.eckey
, 16);
}
else
#endif
}
else
#endif
@@
-444,15
+444,17
@@
err:
int X509_NAME_print(BIO *bp, X509_NAME *name, int obase)
{
int X509_NAME_print(BIO *bp, X509_NAME *name, int obase)
{
- char *s,*c;
+ char *s,*c
,*b
;
int ret=0,l,ll,i,first=1;
int ret=0,l,ll,i,first=1;
- char buf[256];
ll=80-2-obase;
ll=80-2-obase;
-
s=X509_NAME_oneline(name,buf,256
);
+
b=s=X509_NAME_oneline(name,NULL,0
);
if (!*s)
if (!*s)
+ {
+ OPENSSL_free(b);
return 1;
return 1;
+ }
s++; /* skip the first slash */
l=ll;
s++; /* skip the first slash */
l=ll;
@@
-508,6
+510,7
@@
int X509_NAME_print(BIO *bp, X509_NAME *name, int obase)
err:
X509err(X509_F_X509_NAME_PRINT,ERR_R_BUF_LIB);
}
err:
X509err(X509_F_X509_NAME_PRINT,ERR_R_BUF_LIB);
}
+ OPENSSL_free(b);
return(ret);
}
return(ret);
}