On 09/22/2010 07:15 AM, Hardy Griech wrote:

> :
>> Why wouldn't it be? Did you notice any issues? mod_gnutls only offers
>> the secure layer. The HTTP is still handled by apache thus anything that
>> worked without mod_gnutls should work with it.
> :
> 
> Perhaps this is the problem (from error.log):
> 
> [Wed Sep 22 07:13:59 2010] [debug] gnutls_cache.c(461): (22)Invalid 
> argument: [gnutls_cache] error storing in cache 
> '/var/cache/apache2/gnutls_cache'

This isn't really relevant. Is the argument a directory? It should be a
file on a writable directory.

> What is there wrong?

Could you check the attached patch? Does it fix your issue?

regards,
Nikos
diff --git a/src/gnutls_io.c b/src/gnutls_io.c
index ba03fce..6db2b28 100644
--- a/src/gnutls_io.c
+++ b/src/gnutls_io.c
@@ -555,15 +555,7 @@ apr_status_t mgs_filter_output(ap_filter_t * f,
     while (!APR_BRIGADE_EMPTY(bb)) {
         apr_bucket *bucket = APR_BRIGADE_FIRST(bb);
         
-        if (AP_BUCKET_IS_EOC(bucket) || APR_BUCKET_IS_EOS(bucket)) {
-            apr_bucket_brigade * tmpb;
-            
-            if (APR_BUCKET_IS_EOS(bucket)) {
-                tmpb = bb;
-            } else {
-                tmpb = ctxt->output_bb;
-            }
-            
+        if (AP_BUCKET_IS_EOC(bucket)) {
             if (ctxt->session != NULL) {
                 do {
                     ret = gnutls_bye( ctxt->session, GNUTLS_SHUT_WR);
@@ -573,7 +565,7 @@ apr_status_t mgs_filter_output(ap_filter_t * f,
             apr_bucket_copy(bucket, &e);
             APR_BRIGADE_INSERT_TAIL(ctxt->output_bb, e);
  
-            if ((status = ap_pass_brigade(f->next, tmpb)) != APR_SUCCESS) {
+            if ((status = ap_pass_brigade(f->next, ctxt->output_bb)) != 
APR_SUCCESS) {
                 apr_brigade_cleanup(ctxt->output_bb);
                 return status;
             }
@@ -584,7 +576,7 @@ apr_status_t mgs_filter_output(ap_filter_t * f,
                 ctxt->session = NULL;
             }
             continue;
-        } else if (APR_BUCKET_IS_FLUSH(bucket)) {
+        } else if (APR_BUCKET_IS_FLUSH(bucket) || APR_BUCKET_IS_EOS(bucket)) {
 
             apr_bucket_copy(bucket, &e);
             APR_BRIGADE_INSERT_TAIL(ctxt->output_bb, e);
_______________________________________________
Modules mailing list
Modules@lists.outoforder.cc
http://lists.outoforder.cc/mailman/listinfo/modules

Reply via email to