Richard Levitte - VMS Whacker <[EMAIL PROTECTED]>:
>> SSLeay_add_ssl_algorithms (); <---*****(1)
>> SSL_load_error_strings (); <---*****(1)
> (1) These are really only mean to be used ONCE for the whole
> application. The ssl algorithm table and the error message table
> is global. [...]
Yup.
>> // Cleanup and exit.
>> if (pSsl) SSL_shutdown (pSsl);
>>
>> iRetCode = shutdown (sSocket, SD_BOTH);
>> closesocket (sSocket);
>> if (pSsl) SSL_free (pSsl);
> THAT sequence gives me the creaps (sp?). You see, the fd's you
> declared earlier with SSL_set_fd() got "registered" in the SSL
> structure through a couple of BIOs. SSL_free() will fo a
> BIO_free_all() on those, and BIO_free_all() will most definitely try
> to close the socket...
Actually not, because SSL_set_fd uses BIO_set_fd(bio,fd,BIO_NOCLOSE).
You have to close the sockets yourself when using SSL_set_fd.
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]