Return-Path: Delivered-To: apmail-httpd-dev-archive@httpd.apache.org Received: (qmail 18925 invoked by uid 500); 21 Feb 2002 04:21:27 -0000 Mailing-List: contact dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list dev@httpd.apache.org Received: (qmail 18912 invoked from network); 21 Feb 2002 04:21:26 -0000 Message-ID: <3C7475CE.5040201@apache.org> Date: Wed, 20 Feb 2002 20:21:34 -0800 From: Ian Holsman User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.8+) Gecko/20020212 X-Accept-Language: en-us MIME-Version: 1.0 To: dev@httpd.apache.org Subject: [patch] mod-include fix Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N can other people please sanity check this patch the case it is trying to fix is the case where the end of a bucket has the start of a SSI tag .. 'ie a <' and the next bucket is found not to match the SSI tag.. '/table>' for example. this sends the '<' out. Index: mod_include.c =================================================================== RCS file: /home/cvs/httpd-2.0/modules/filters/mod_include.c,v retrieving revision 1.188 diff -u -r1.188 mod_include.c --- mod_include.c 21 Jan 2002 01:43:30 -0000 1.188 +++ mod_include.c 21 Feb 2002 04:01:18 -0000 @@ -429,7 +429,18 @@ return found_start_sequence(dptr, ctx, c - buf); } - /* False alarm... */ + /* False alarm... + * send out the unmatched part + */ + if (ctx->parse_pos >0) { + apr_bucket *tmp_buck; + tmp_buck = apr_bucket_pool_create(apr_pstrndup(ctx->pool, + ctx->start_seq, + ctx->parse_pos), + ctx->parse_pos, + ctx->pool); + APR_BUCKET_INSERT_BEFORE(dptr, tmp_buck); + } ctx->state = PRE_HEAD; }