[php-src] master: Merge branch 'PHP-8.6'
| From: | ndossche | Date: | Sun, 01 Nov 2026 12:49:38 +0000 |
| Subject: | [php-src] master: Merge branch 'PHP-8.6' | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-143137@lists.php.net to get a copy of this message | ||
Author: ndossche (ndossche)
Date: 2026-11-01T13:49:25+01:00
Commit: https://github.com/php/php-src/commit/34098edca09dca1ba9cb4429d4b2146db5570f3e
Raw diff: https://github.com/php/php-src/commit/34098edca09dca1ba9cb4429d4b2146db5570f3e.diff
Merge branch 'PHP-8.6'
* PHP-8.6:
Fix GH-25009: GetConsoleTitleW() buffer size passed in bytes
Changed paths:
M sapi/cli/ps_title.c
Diff:
diff --git a/sapi/cli/ps_title.c b/sapi/cli/ps_title.c
index ee977cd88cd1..9c6972d8c7b5 100644
--- a/sapi/cli/ps_title.c
+++ b/sapi/cli/ps_title.c
@@ -415,7 +415,7 @@ ps_title_status get_ps_title(size_t *displen, const char** string)
wchar_t ps_buffer_w[MAX_PATH];
char *tmp;
- if (!(ps_buffer_cur_len = GetConsoleTitleW(ps_buffer_w, (DWORD)sizeof(ps_buffer_w)))) {
+ if (!(ps_buffer_cur_len = GetConsoleTitleW(ps_buffer_w, (DWORD)(sizeof(ps_buffer_w) /
sizeof(ps_buffer_w[0]))))) {
return PS_TITLE_WINDOWS_ERROR;
}