diff options
Diffstat (limited to 'crypto/openssl/apps/spkac.c')
-rw-r--r-- | crypto/openssl/apps/spkac.c | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/crypto/openssl/apps/spkac.c b/crypto/openssl/apps/spkac.c index f3ee7e3..459d730 100644 --- a/crypto/openssl/apps/spkac.c +++ b/crypto/openssl/apps/spkac.c @@ -192,7 +192,15 @@ bad: spkstr = NETSCAPE_SPKI_b64_encode(spki); if (outfile) out = BIO_new_file(outfile, "w"); - else out = BIO_new_fp(stdout, BIO_NOCLOSE); + else { + out = BIO_new_fp(stdout, BIO_NOCLOSE); +#ifdef VMS + { + BIO *tmpbio = BIO_new(BIO_f_linebuffer()); + out = BIO_push(tmpbio, out); + } +#endif + } if(!out) { BIO_printf(bio_err, "Error opening output file\n"); @@ -200,7 +208,7 @@ bad: goto end; } BIO_printf(out, "SPKAC=%s\n", spkstr); - Free(spkstr); + OPENSSL_free(spkstr); ret = 0; goto end; } @@ -241,7 +249,15 @@ bad: } if (outfile) out = BIO_new_file(outfile, "w"); - else out = BIO_new_fp(stdout, BIO_NOCLOSE); + else { + out = BIO_new_fp(stdout, BIO_NOCLOSE); +#ifdef VMS + { + BIO *tmpbio = BIO_new(BIO_f_linebuffer()); + out = BIO_push(tmpbio, out); + } +#endif + } if(!out) { BIO_printf(bio_err, "Error opening output file\n"); @@ -268,9 +284,9 @@ end: CONF_free(conf); NETSCAPE_SPKI_free(spki); BIO_free(in); - BIO_free(out); + BIO_free_all(out); BIO_free(key); EVP_PKEY_free(pkey); - if(passin) Free(passin); + if(passin) OPENSSL_free(passin); EXIT(ret); } |