httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <jor...@redhat.com>
Subject Re: svn commit: r1051468 - in /httpd/httpd/trunk: CHANGES modules/ssl/ssl_engine_io.c
Date Fri, 14 Jan 2011 14:41:58 GMT
On Thu, Jan 13, 2011 at 03:25:22PM +0100, "Plüm, Rüdiger, VF-Group" wrote:
> Should I commit the patch below now to resolve the issue and address
> your point?

Once again we are struggling with the ill-defined filtering API :(

You're proposing here to make the _GETLINE call return a partial read in 
a case where no LF is found.  I think most existing callers would 
probably cope fine with that, but the wording in util_filter.h is 
explicit:

     *  (If a potential line is too long or no CRLF is found, the               
     *   filter may return partial data).                                       

i.e. it does not make mention of non-blocking mode.

So I think it would be best to revert the second half of the patch and 
leave the first half as-is, i.e. patch as below - if this makes sense to 
you also?  

I've been trying to make a test case which tickles this issue but have 
so far not managed to get a non-blocking GETLINE call with the filter in 
the right state.

Index: modules/ssl/ssl_engine_io.c
===================================================================
--- modules/ssl/ssl_engine_io.c	(revision 1054976)
+++ modules/ssl/ssl_engine_io.c	(working copy)
@@ -786,10 +786,6 @@
 
         *len = bytes;
     }
-    else {
-        /* Safe the part of the line we already got */
-        char_buffer_write(&inctx->cbuf, buf, *len);
-    }
 
     return APR_SUCCESS;
 }


Mime
View raw message