From: Cliff Woolley Date: Mon, 23 Jul 2001 13:45:44 +0000 (+0000) Subject: The bucket should be created with the size of the data NOT including a null X-Git-Tag: 2.0.22~61 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee760bf405331e4c1fc350ec4df1b1a5d5de47f9;p=thirdparty%2Fapache%2Fhttpd.git The bucket should be created with the size of the data NOT including a null terminator as its length. Otherwise, the bucket length value is wrong (too big by one). git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89654 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/filters/mod_include.c b/modules/filters/mod_include.c index 22bf605e6dd..b4540074b35 100644 --- a/modules/filters/mod_include.c +++ b/modules/filters/mod_include.c @@ -914,7 +914,7 @@ static int handle_echo(include_ctx_t *ctx, apr_bucket_brigade **bb, request_rec tmp_buck = apr_bucket_heap_create(echo_text, e_len, 1, &e_wrt); } else { - tmp_buck = apr_bucket_immortal_create("(none)", sizeof("(none)")); + tmp_buck = apr_bucket_immortal_create("(none)", sizeof("(none)")-1); } APR_BUCKET_INSERT_BEFORE(head_ptr, tmp_buck); if (*inserted_head == NULL) {