From: Doug MacEachern Date: Tue, 24 Jul 2001 19:00:12 +0000 (+0000) Subject: bandaid for segv in ssl_io_filter_Output X-Git-Tag: 2.0.22~43 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8d045a3727843c30ac6140d43652d40e2013034d;p=apache bandaid for segv in ssl_io_filter_Output git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89681 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/ssl/ssl_engine_io.c b/modules/ssl/ssl_engine_io.c index f89ef4df06..8e03e52597 100644 --- a/modules/ssl/ssl_engine_io.c +++ b/modules/ssl/ssl_engine_io.c @@ -323,7 +323,17 @@ apr_status_t ssl_io_filter_Output(ap_filter_t *f,apr_bucket_brigade *pbbIn) { SSLFilterRec *pRec=f->ctx; apr_bucket *pbktIn; -conn_rec *c = SSL_get_app_data (pRec->pssl); + conn_rec *c = SSL_get_app_data (pRec->pssl); + + if (!c) { + /* if this happens we have already called ssl_hook_CloseConnection + * if we dont return here, this routine will segv + * XXX: this doesnt seem right, ssl_hook_CloseConnection probably + * is being called to early, but as the README:TODO says: + * "Cleanup ssl_engine_io.c !!" + */ + return APR_EOF; + } APR_BRIGADE_FOREACH(pbktIn,pbbIn) { const char *data;