oh
when application crash .. it normally beacause link mfc lib
problem
you
may try use mfc in shared dll or mfc in static dll
it
may ok..
as
for memory leak ..
begin ..
OpenSSL_add_all_algorithms();
SSL_load_error_strings();
SSL_load_error_strings();
your code...
End:
ERR_free_strings();
EVP_cleanup();
EVP_cleanup();
see
u later...:)
-----原始邮件-----
发件人: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]代表 Jordan C N Chong
发送时间: 2001年9月10日 19:43
收件人: [EMAIL PROTECTED]
主题: RE: Please Help: BIO!!Hi,Thanks for your reply. I have tried, still the memory leak problem happens :)and the whole application crashesmy code is like this:BIO *bio, *b64;
BIO *bio_out;
char inbuf[128];
int inlen;
b64 = BIO_new(BIO_f_base64());
bio = BIO_new_file("content.key", "rb");
bio_out = BIO_new_fp(stdout, BIO_NOCLOSE);
bio = BIO_push(b64, bio);
while ((inlen = BIO_read(bio, inbuf, 128)) > 0) {
BIO_write(bio_out, inbuf, inlen);
}BIO_free_all(bio);what I wish to do is, read the data from the file content.keyand then decode the dataand then convert the decoded data in to a char * (or perhaps to another new file)but here what i do is just print out the decoded data :)i am sorry to bother you that much.pls forgiveand pls help if you have the time :Dthousand thanks. Wish you all the best.Best regards,
--------------------------------------------
Jordan Cheun Ngen, Chong
INF-4067 Universiteit Twente
Postbus 217
7500 AE Enschede
The Netherlands
Distributed and Embedded Systems (DIES)
--------------------------------------------
Office Phone: +31 53 4894655
Web site: http://www.cs.utwente.nl/~chong
Email Add.: [EMAIL PROTECTED]
============================================-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of ??
Sent: Monday, September 10, 2001 1:24 PM
To: '[EMAIL PROTECTED]'
Subject: ??: Please Help: Crypto library with Visual C++oh nothing.... do not be nervousi think if you want to read data from a filefirst you must construct aBIO * mbio = BIO_new_file(filename , "rb") objectthen build another BIO* b64 = BIO_new(BIO_f_base64());then mbio = BIO_push(b64, mbio);all ok ...read data fromwhile((inlen = BIO_read(mbio, inbuf, strlen(message))) > 0){....do as you wish}
// remember free all bio resourceBIO_free_all(bio); can this solve your problem?