From 577b8ae4226368e66fee7a9b5c58f9e2428372fc Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 8 Apr 2024 14:58:12 +0200 Subject: [PATCH 1/2] Fix cookie_seek_function_t signature under musl (#13890) Fixes GH-11678 --- main/streams/cast.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/main/streams/cast.c b/main/streams/cast.c index 3bad65fbac1..8d9f4a9d2d5 100644 --- a/main/streams/cast.c +++ b/main/streams/cast.c @@ -104,6 +104,9 @@ static ssize_t stream_cookie_writer(void *cookie, const char *buffer, size_t siz # ifdef COOKIE_SEEKER_USES_OFF64_T static int stream_cookie_seeker(void *cookie, off64_t *position, int whence) +# else +static int stream_cookie_seeker(void *cookie, off_t *position, int whence) +# endif { *position = php_stream_seek((php_stream *)cookie, (zend_off_t)*position, whence); @@ -113,13 +116,6 @@ static int stream_cookie_seeker(void *cookie, off64_t *position, int whence) } return 0; } -# else -static int stream_cookie_seeker(void *cookie, zend_off_t position, int whence) -{ - - return php_stream_seek((php_stream *)cookie, position, whence); -} -# endif static int stream_cookie_closer(void *cookie) { From 85d621242a09ad9b36f511b613777352cb90c7f4 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 8 Apr 2024 15:01:15 +0200 Subject: [PATCH 2/2] [ci skip] NEWS --- NEWS | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 227ae6f0b2d..5d140d27e5a 100644 --- a/NEWS +++ b/NEWS @@ -27,13 +27,14 @@ PHP NEWS . Fixed bug GH-13856 (Member access within null pointer of type 'ps_files' in ext/session/mod_files.c). (nielsdos) . Fixed bug GH-13891 (memleak and segfault when using ini_set with - session.trans_sid_hosts). (nielsdos, kamil-tekiela). + session.trans_sid_hosts). (nielsdos, kamil-tekiela) - Streams: . Fixed bug GH-13264 (Part 1 - Memory leak on stream filter failure). (Jakub Zelenka) . Fixed bug GH-13860 (Incorrect PHP_STREAM_OPTION_CHECK_LIVENESS case in ext/openssl/xp_ssl.c - causing use of dead socket). (nielsdos) + . Fixed bug GH-11678 (Build fails on musl 1.2.4 - lfs64). (Arnaud) - Treewide: . Fix gcc-14 Wcalloc-transposed-args warnings. (Cristian Rodríguez)