Skip to content

Commit

Permalink
do not mark headers as sent before header callback
Browse files Browse the repository at this point in the history
  • Loading branch information
kojidev committed Dec 16, 2024
1 parent 54cb7bc commit ddeb7db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -593,10 +593,10 @@ void f$flush() {
void f$fastcgi_finish_request(int64_t exit_code) {
// Run custom headers handler before body processing
if (!headers_sent && query_type == QUERY_TYPE_HTTP) {
headers_sent = true;
if (headers_custom_handler_function) {
headers_custom_handler_function();
}
headers_sent = true;
}
int ob_total_buffer = ob_merge_buffers();
if (php_worker.has_value() && php_worker->flushed_http_connection) {
Expand Down

0 comments on commit ddeb7db

Please sign in to comment.