Hi all!

What's wrong with this program:

----- start ----------
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/bio.h>
#ifdef __cplusplus
}
#endif

int main ( int argc, char* argv[] )
{
    BIO *bio_err;
    if ((bio_err=BIO_new(BIO_s_file())) != NULL)
        BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
    else
    { printf( "Bad boy\n" ); exit( 1 ); }
    BIO_printf(bio_err,"test message\n");
    exit( 0 );
}
---- end --------

It crashes when it tries to do 'BIO_printf'. The program was built with
openssl-0.9.5a on Windows NT Workstation. Build and test have passed OK
and openssl utility works OK. I am trying to do some work in digital
signing, but I cannot move very far. I suspect BIO module requires some
setup, but I don't know what setup, and there's no documentation.

Thanks,
Milan
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to