]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
The bucket should be created with the size of the data NOT including a null
authorCliff Woolley <jwoolley@apache.org>
Mon, 23 Jul 2001 13:45:44 +0000 (13:45 +0000)
committerCliff Woolley <jwoolley@apache.org>
Mon, 23 Jul 2001 13:45:44 +0000 (13:45 +0000)
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

modules/filters/mod_include.c

index 22bf605e6dd6415e19ca52a42dfb84911e95665e..b4540074b3503f5dcfd18af6fc250421e4487588 100644 (file)
@@ -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) {