openssl s_server command outputs to stdout messages, indicating current
state of server, such as "ACCEPT", "DONE", "ERROR". 

When s_server is run interactively, these messages appear on the console
in time, and user can see it.

But, when s_server is run from some other process via pipe, standard
output is buffered in the s_server process. So, it is not possible to 
control s_server programmaticaly without allocating pseudoterminal.

In some cases it is highly desirable to be able to control s_server and
s_client from some script (for instance for automatic tests).

Following patch fixes this problem by adding BIO_flush call after
outputting of some messages. 

This approach doesn't have performance penalty of fully unbuffered
output, but ensures that reader of s_server standard output would see
messages in time (Of course reader process should use unbuffered input,
but it is usially no problem).

Patch is made against 0.9.8 release.

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       openssl-dev@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to