diff options
author | Nokis Mavrogiannopoulos | 2009-07-20 20:39:22 +0000 |
---|---|---|
committer | Nokis Mavrogiannopoulos | 2009-07-20 20:39:22 +0000 |
commit | 7b3eebe6f8cde42b78ae668ab29ea254f38fbcd6 (patch) | |
tree | 7c89f4f13ff235dc17275b9abe717ff40021f90c /src/gnutls_io.c | |
parent | 4196f5acb2bd1161bca1f3ac4ac1568b3b43bddb (diff) |
only call gnutls_bye on non null gnutls session.
Diffstat (limited to 'src/gnutls_io.c')
-rw-r--r-- | src/gnutls_io.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/gnutls_io.c b/src/gnutls_io.c index b06afd7..a8fd242 100644 --- a/src/gnutls_io.c +++ b/src/gnutls_io.c | |||
@@ -544,9 +544,11 @@ apr_status_t mgs_filter_output(ap_filter_t * f, | |||
544 | while (!APR_BRIGADE_EMPTY(bb)) { | 544 | while (!APR_BRIGADE_EMPTY(bb)) { |
545 | apr_bucket *bucket = APR_BRIGADE_FIRST(bb); | 545 | apr_bucket *bucket = APR_BRIGADE_FIRST(bb); |
546 | if (AP_BUCKET_IS_EOC(bucket)) { | 546 | if (AP_BUCKET_IS_EOC(bucket)) { |
547 | do { | 547 | if (ctxt->session != NULL) { |
548 | ret = gnutls_bye( ctxt->session, GNUTLS_SHUT_WR); | 548 | do { |
549 | } while(ret == GNUTLS_E_INTERRUPTED || ret == GNUTLS_E_AGAIN); | 549 | ret = gnutls_bye( ctxt->session, GNUTLS_SHUT_WR); |
550 | } while(ret == GNUTLS_E_INTERRUPTED || ret == GNUTLS_E_AGAIN); | ||
551 | } | ||
550 | 552 | ||
551 | apr_bucket_copy(bucket, &e); | 553 | apr_bucket_copy(bucket, &e); |
552 | APR_BRIGADE_INSERT_TAIL(ctxt->output_bb, e); | 554 | APR_BRIGADE_INSERT_TAIL(ctxt->output_bb, e); |