Skip to content

Commit 4e1523a

Browse files
committed
Fix ATS does not honor proxy.config.body_factory.response_max_size
1 parent 04bfb45 commit 4e1523a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

proxy/http/HttpTransact.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7979,9 +7979,9 @@ HttpTransact::build_error_response(State *s, HTTPStatus status_code, const char
79797979
int64_t len;
79807980
char *new_msg;
79817981

7982-
new_msg = body_factory->fabricate_with_old_api(error_body_type, s, 8192, &len, body_language, sizeof(body_language), body_type,
7983-
sizeof(body_type), s->internal_msg_buffer_size,
7984-
s->internal_msg_buffer_size ? s->internal_msg_buffer : nullptr);
7982+
new_msg = body_factory->fabricate_with_old_api(
7983+
error_body_type, s, s->http_config_param->body_factory_response_max_size, &len, body_language, sizeof(body_language), body_type,
7984+
sizeof(body_type), s->internal_msg_buffer_size, s->internal_msg_buffer_size ? s->internal_msg_buffer : nullptr);
79857985

79867986
// After the body factory is called, a new "body" is allocated, and we must replace it. It is
79877987
// unfortunate that there's no way to avoid this fabrication even when there is no substitutions...

0 commit comments

Comments
 (0)