From 03b8f85c882fd365fad90721691d003326574267 Mon Sep 17 00:00:00 2001 From: Brian Pane Date: Mon, 7 Oct 2002 15:30:43 +0000 Subject: [PATCH] Fixed the new send_all_header_fields() function to properly compute the size of the iovec array. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97135 13f79535-47bb-0310-9956-ffa450edef68 --- modules/http/http_protocol.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/http/http_protocol.c b/modules/http/http_protocol.c index b4efb09bb9..6730df6dcf 100644 --- a/modules/http/http_protocol.c +++ b/modules/http/http_protocol.c @@ -1168,7 +1168,8 @@ static apr_status_t send_all_header_fields(header_struct *h, } t_elt = (const apr_table_entry_t *)(elts->elts); t_end = t_elt + elts->nelts; - vec = (struct iovec *)apr_palloc(h->pool, 4 * elts->nelts); + vec = (struct iovec *)apr_palloc(h->pool, 4 * elts->nelts * + sizeof(struct iovec)); vec_next = vec; /* For each field, generate -- 2.40.0