]> granicus.if.org Git - php/commitdiff
Fix for Bug #9280 with regards to an Expect header. patch submitted by
authorDan Kalowsky <kalowsky@php.net>
Wed, 14 Aug 2002 17:15:49 +0000 (17:15 +0000)
committerDan Kalowsky <kalowsky@php.net>
Wed, 14 Aug 2002 17:15:49 +0000 (17:15 +0000)
Ilia <ilia@prohost.org>
# someone just give the man his php4 karma please!

sapi/apache/mod_php4.c

index 3aaa6bafb94ce9ba7e5606e28090771e83e79042..19d03f7e36121fdb84da627c02487e7ef04d605f 100644 (file)
@@ -129,6 +129,14 @@ int sapi_apache_read_post(char *buffer, uint count_bytes TSRMLS_DC)
        request_rec *r = (request_rec *) SG(server_context);
        void (*handler)(int);
 
+       /*
+        * This handles the situation where the browser sends a Expect: 100-continue header
+        * and needs to recieve confirmation from the server on whether or not it can send
+        * the rest of the request. RFC 2616
+        *
+        */
+       if( !ap_should_client_block(r) ) return total_read_bytes;
        handler = signal(SIGPIPE, SIG_IGN);
        while (total_read_bytes<count_bytes) {
                hard_timeout("Read POST information", r); /* start timeout timer */