File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ PHP NEWS
88 . Fixed bug GH-23301 (Nested "yield from" yields a value twice when the
99 middle generator delegates again). (Lazizbek Ergashev)
1010
11+ - CLI:
12+ . Fixed bug GH-23425 (sapi_cli_server_send_headers() does not check the
13+ return value of php_cli_server_client_send_through()). (Lazizbek Ergashev)
14+
1115- DOM:
1216 . Fixed a use-after-free when cloning a DOMNameSpaceNode after
1317 DOMDocument::xinclude(). (iliaal)
Original file line number Diff line number Diff line change @@ -578,10 +578,11 @@ static int sapi_cli_server_send_headers(sapi_headers_struct *sapi_headers) /* {{
578578 }
579579 smart_str_appendl (& buffer , "\r\n" , 2 );
580580
581- php_cli_server_client_send_through (client , ZSTR_VAL (buffer .s ), ZSTR_LEN (buffer .s ));
581+ size_t buffer_len = ZSTR_LEN (buffer .s );
582+ bool sent = php_cli_server_client_send_through (client , ZSTR_VAL (buffer .s ), buffer_len ) == buffer_len ;
582583
583584 smart_str_free (& buffer );
584- return SAPI_HEADER_SENT_SUCCESSFULLY ;
585+ return sent ? SAPI_HEADER_SENT_SUCCESSFULLY : SAPI_HEADER_SEND_FAILED ;
585586}
586587/* }}} */
587588
You can’t perform that action at this time.
0 commit comments