Skip to content

Commit

Permalink
lib-ssl-iostream: ostream-openssl: Create local variable for sstream-…
Browse files Browse the repository at this point in the history
…>ssl_io->plain_output in o_stream_ssl_flush().
  • Loading branch information
stephanbosch authored and villesavolainen committed Feb 22, 2018
1 parent 01b3674 commit 3dfd5e1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib-ssl-iostream/ostream-openssl.c
Expand Up @@ -117,6 +117,7 @@ static int o_stream_ssl_flush_buffer(struct ssl_ostream *sstream)
static int o_stream_ssl_flush(struct ostream_private *stream)
{
struct ssl_ostream *sstream = (struct ssl_ostream *)stream;
struct ostream *plain_output = sstream->ssl_io->plain_output;
int ret;

if ((ret = openssl_iostream_more(sstream->ssl_io)) < 0) {
Expand All @@ -132,8 +133,7 @@ static int o_stream_ssl_flush(struct ostream_private *stream)

if (ret == 0 && sstream->ssl_io->want_read) {
/* we need to read more data until we can continue. */
o_stream_set_flush_pending(sstream->ssl_io->plain_output,
FALSE);
o_stream_set_flush_pending(plain_output, FALSE);
sstream->ssl_io->ostream_flush_waiting_input = TRUE;
ret = 1;
}
Expand Down

0 comments on commit 3dfd5e1

Please sign in to comment.