Skip to content

sync #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 87 commits into from
Dec 14, 2022
Merged

sync #20

Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
bcc0030
Updated to version 2022.7 (2022g)
derickr Nov 29, 2022
6f71697
Empty merge
derickr Nov 29, 2022
e568f93
Updated to version 2022.7 (2022g)
derickr Nov 29, 2022
ac1b232
Empty merge
derickr Nov 29, 2022
ebde5d3
Updated to version 2022.7 (2022g)
derickr Nov 29, 2022
44377c3
Fix GH-9971: Incorrect NUMERIC value returned from PDO_Firebird
cmb69 Nov 29, 2022
e29ca36
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Nov 30, 2022
7402d90
Merge branch 'PHP-8.2'
cmb69 Nov 30, 2022
818b46a
Import timelib 2021.18
derickr Nov 30, 2022
d021851
Fixed GH-9699, GH-9866, and GH-9880 (problems with diff); and GH-9700…
derickr Nov 30, 2022
64f5f53
Merge remote-tracking branch 'derickr/timelib-2021.18' into PHP-8.1
derickr Nov 30, 2022
83b714d
Merge branch 'PHP-8.1' into PHP-8.2
derickr Nov 30, 2022
f9ef2db
Merge branch 'PHP-8.2'
derickr Nov 30, 2022
41fef8b
Import timelib 2022.03
derickr Nov 30, 2022
d6ac533
Merge branch 'PHP-8.2'
derickr Nov 30, 2022
c87c803
Some (old, backwards compatible) TZIDs can have numbers in them
derickr Dec 1, 2022
29f0f4e
Merge branch 'regression-tzid-with-numbers' into PHP-8.1
derickr Dec 1, 2022
1316a5b
Merge branch 'PHP-8.1' into PHP-8.2
derickr Dec 1, 2022
853e9ca
Merge branch 'PHP-8.2'
derickr Dec 1, 2022
d4c804b
[ci skip] Add missing entries to php.ini quick reference
cmb69 Dec 1, 2022
683d81e
Fix incorrect short-circuiting in constant expressions (#10030)
iluuu1994 Dec 1, 2022
93592ea
Fix GH-9769: Misleading error message for unpacking of objects
jhdxr Nov 17, 2022
6b1f4c5
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 2, 2022
9f0e4a5
Merge branch 'PHP-8.2'
cmb69 Dec 2, 2022
c4a0fc6
Fix zend_fcc_equals() with trampolines (#10012)
Girgias Dec 2, 2022
608ddb0
Fix GH-10011 (Trampoline autoloader will get reregistered and cannot …
Girgias Dec 2, 2022
334d108
Merge branch 'PHP-8.1' into PHP-8.2
Girgias Dec 2, 2022
d952419
Merge branch 'PHP-8.2'
Girgias Dec 2, 2022
adc2382
Fallback to first line of function when ex->opline is NULL (#10003)
arnaud-lb Dec 2, 2022
b683a7e
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 5, 2022
6109b80
Merge branch 'PHP-8.2'
cmb69 Dec 5, 2022
b6b4a62
ext/mysqli tests "using password" optional in error messages
grooverdan Dec 2, 2022
0ac9e8e
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 5, 2022
4ae1f08
Merge branch 'PHP-8.2'
cmb69 Dec 5, 2022
e4ef394
Drop superfluous check for imap_stream
cmb69 Dec 5, 2022
2f6b9e6
Fix #81742: open_basedir bypass in SQLite3 by using file URI
cmb69 Dec 5, 2022
8301803
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 6, 2022
568ed47
Merge branch 'PHP-8.2'
cmb69 Dec 6, 2022
696bb38
PHP-8.1 is now for PHP 8.1.15-dev
ramsey Dec 7, 2022
35a4950
Replace Azure DevOps link with GitHub Actions
ramsey Dec 7, 2022
11b612a
Rename PHP_STREAM_TO_ZVAL to PHP_STREAM_FROM_ZVAL (#10065)
nielsdos Dec 7, 2022
3f3c1df
[ci skip] Fix GH-10056: [grammar] "less security-conscience applicati…
cmb69 Dec 8, 2022
01eabdc
[ci skip] Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 8, 2022
b628989
[ci skip] Merge branch 'PHP-8.2'
cmb69 Dec 8, 2022
c21a592
ext/mysqli tests "using password" optional in error messages (part 2)
grooverdan Dec 7, 2022
a76bbd3
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 8, 2022
005a765
Merge branch 'PHP-8.2'
cmb69 Dec 8, 2022
faef55d
standard/basic_functions.c remove x bit on this file (#10069)
devnexen Dec 9, 2022
a1a69c3
Support Microsoft's "Best Fit" mappings for Windows-1252 text encoding
alexdowad Dec 6, 2022
b79a86f
Merge branch 'PHP-8.1' into PHP-8.2
alexdowad Dec 9, 2022
14110bf
Merge branch 'PHP-8.2'
alexdowad Dec 9, 2022
b77edf8
Fix mysqli test wrt. MariaDB
grooverdan Dec 1, 2022
1b503a1
Merge branch 'PHP-8.2'
cmb69 Dec 9, 2022
ac3ecd0
Add `Randomizer::getBytesFromString()` method (#9664)
joshuaruesweg Dec 9, 2022
16ce751
[ci skip] Add json_validate() RFC link to UPGRADING
TimWolla Dec 9, 2022
b34cdc5
[ci skip] Fix json_validate() formatting in NEWS
TimWolla Dec 9, 2022
6422cf6
intl extension: msgfmt_set_pattern add pattern format error informati…
devnexen Nov 27, 2022
e114f32
Avoid code duplication in php_ini.c (#4512)
glensc Dec 10, 2022
8a221e2
fix litespeed SAPI build warnings.
devnexen Dec 10, 2022
91e70a4
Merge branch 'PHP-8.2'
devnexen Dec 10, 2022
a839230
Fix compilation on RHEL 7 ppc64le (gcc 4.8)
ellert Nov 30, 2021
b96b88b
Merge branch 'PHP-8.2'
iluuu1994 Dec 11, 2022
0c0774f
Use fast text conversion filters for mb_strpos, mb_stripos, mb_substr…
alexdowad Oct 4, 2022
b3d197d
Optimize SJIS decoder for speed
alexdowad Dec 2, 2022
4072a76
Move MacJapanese implementation into mbfilter_sjis.c
alexdowad Dec 3, 2022
005e49e
Optimize MacJapanese decoder for speed
alexdowad Dec 3, 2022
4ebfddf
Move mobile variants of SJIS into mbfilter_sjis.c
alexdowad Dec 3, 2022
43cdfa3
Optimize SJIS-Mobile#DOCOMO decoder for speed
alexdowad Dec 3, 2022
6bf0c44
Optimize SJIS-Mobile#KDDI decoder for speed
alexdowad Dec 3, 2022
e36c600
Optimize SJIS-Mobile#SOFTBANK decoder for speed
alexdowad Dec 4, 2022
3be2b0d
Add CLEAN section to some IO tests (#10081)
Girgias Dec 12, 2022
fa3bbf0
Fix borked Windows tests after 3be2b0d0d83702db409bfcc3fbb4a176d565932d
Girgias Dec 12, 2022
3fb7198
intl extension, follow up on #10006 for numfmt_set_pattern
devnexen Dec 9, 2022
c5ab727
[skip ci] Change status of BCMath into Maintained (#10089)
frederikbosch Dec 13, 2022
3ab18d4
Change if (stack) check to an assertion (#10090)
nielsdos Dec 13, 2022
aef7d81
Fix GH-9949: Partial content on incomplete POST request
cmb69 Dec 6, 2022
87c2f5b
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 13, 2022
2ca03be
Merge branch 'PHP-8.2'
cmb69 Dec 13, 2022
7a983e2
Fix Windows shmget() wrt. IPC_PRIVATE
TysonAndre Nov 15, 2022
9089e15
Merge branch 'PHP-8.1' into PHP-8.2
cmb69 Dec 13, 2022
b593b53
Merge branch 'PHP-8.2'
cmb69 Dec 13, 2022
4631e9d
shmget() with IPC_CREAT must not create 0 size SHM
cmb69 Dec 13, 2022
f8ff105
Merge branch 'PHP-8.2'
cmb69 Dec 13, 2022
52a891a
Add a new imap_is_open() function to check that a connection object i…
Girgias Dec 13, 2022
4a36513
Merge branch 'PHP-8.2'
Girgias Dec 13, 2022
002d54d
PHP-8.2 is now for PHP 8.2.2-dev
adoy Dec 14, 2022
2f119c3
Merge branch 'PHP-8.2'
adoy Dec 14, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 20 additions & 24 deletions sapi/litespeed/lsapi_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -537,9 +537,9 @@ static void log_message (const char *fmt, ...)
#define DEBUG_MESSAGE(fmt, ...)
#endif

static int lsapi_activate_user_ini();
static int lsapi_activate_user_ini(void);

static int sapi_lsapi_activate()
static int sapi_lsapi_activate(void)
{
char *path, *server_name;
size_t path_len, server_name_len;
Expand Down Expand Up @@ -677,10 +677,9 @@ static int do_clean_shutdown = 1;
static int clean_onexit = 1;


static void lsapi_clean_shutdown()
static void lsapi_clean_shutdown(void)
{
struct sigaction act;
int sa_rc;
struct itimerval tmv;
#if PHP_MAJOR_VERSION >= 7
zend_string * key;
Expand All @@ -689,15 +688,14 @@ static void lsapi_clean_shutdown()
sigemptyset(&act.sa_mask);
act.sa_flags = 0;
act.sa_handler = lsapi_sigsegv;
sa_rc = sigaction(SIGINT, &act, NULL);
sa_rc = sigaction(SIGQUIT, &act, NULL);
sa_rc = sigaction(SIGILL, &act, NULL);
sa_rc = sigaction(SIGABRT, &act, NULL);
sa_rc = sigaction(SIGBUS, &act, NULL);
sa_rc = sigaction(SIGSEGV, &act, NULL);
sa_rc = sigaction(SIGTERM, &act, NULL);

sa_rc = sigaction(SIGPROF, &act, NULL);
(void)sigaction(SIGINT, &act, NULL);
(void)sigaction(SIGQUIT, &act, NULL);
(void)sigaction(SIGILL, &act, NULL);
(void)sigaction(SIGABRT, &act, NULL);
(void)sigaction(SIGBUS, &act, NULL);
(void)sigaction(SIGSEGV, &act, NULL);
(void)sigaction(SIGTERM, &act, NULL);
(void)sigaction(SIGPROF, &act, NULL);
memset(&tmv, 0, sizeof(struct itimerval));
tmv.it_value.tv_sec = 0;
tmv.it_value.tv_usec = 100000;
Expand Down Expand Up @@ -738,11 +736,9 @@ static void lsapi_atexit(void)
}
}


static int lsapi_module_main(int show_source)
{
struct sigaction act;
int sa_rc;
if (php_request_startup() == FAILURE ) {
return -1;
}
Expand All @@ -751,13 +747,13 @@ static int lsapi_module_main(int show_source)
sigemptyset(&act.sa_mask);
act.sa_flags = SA_NODEFER;
act.sa_handler = lsapi_sigterm;
sa_rc = sigaction( SIGINT, &act, NULL);
sa_rc = sigaction( SIGQUIT, &act, NULL);
sa_rc = sigaction( SIGILL, &act, NULL);
sa_rc = sigaction( SIGABRT, &act, NULL);
sa_rc = sigaction( SIGBUS, &act, NULL);
sa_rc = sigaction( SIGSEGV, &act, NULL);
sa_rc = sigaction( SIGTERM, &act, NULL);
(void)sigaction( SIGINT, &act, NULL);
(void)sigaction( SIGQUIT, &act, NULL);
(void)sigaction( SIGILL, &act, NULL);
(void)sigaction( SIGABRT, &act, NULL);
(void)sigaction( SIGBUS, &act, NULL);
(void)sigaction( SIGSEGV, &act, NULL);
(void)sigaction( SIGTERM, &act, NULL);

clean_onexit = 0;
}
Expand Down Expand Up @@ -834,7 +830,7 @@ static void user_config_cache_entry_dtor(zval *el)
free(entry);
}

static void user_config_cache_init()
static void user_config_cache_init(void)
{
zend_hash_init(&user_config_cache, 0, NULL, user_config_cache_entry_dtor, 1);
}
Expand Down Expand Up @@ -1101,7 +1097,7 @@ static int lsapi_activate_user_ini( void )
}


static void override_ini()
static void override_ini(void)
{

LSAPI_ForeachSpecialEnv( alter_ini, NULL );
Expand Down
38 changes: 4 additions & 34 deletions sapi/litespeed/lsapilib.c
Original file line number Diff line number Diff line change
Expand Up @@ -922,6 +922,7 @@ static int LSAPI_perror_r( LSAPI_Request * pReq, const char * pErr1, const char
}


#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
static int lsapi_lve_error( LSAPI_Request * pReq )
{
static const char * headers[] =
Expand All @@ -945,10 +946,8 @@ static int lsapi_lve_error( LSAPI_Request * pReq )
return 0;
}


static int lsapi_enterLVE( LSAPI_Request * pReq, uid_t uid )
{
#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
if ( s_lve && uid ) //root user should not do that
{
uint32_t cookie;
Expand All @@ -962,16 +961,13 @@ static int lsapi_enterLVE( LSAPI_Request * pReq, uid_t uid )
return -1;
}
}
#endif

return 0;
}


static int lsapi_jailLVE( LSAPI_Request * pReq, uid_t uid, struct passwd * pw )
{
int ret = 0;
#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
char error_msg[1024] = "";
ret = (*fp_lve_jail)( pw, error_msg );
if ( ret < 0 )
Expand All @@ -981,12 +977,10 @@ static int lsapi_jailLVE( LSAPI_Request * pReq, uid_t uid, struct passwd * pw )
LSAPI_perror_r( pReq, "LSAPI: jail() failure.", NULL );
return -1;
}
#endif
return ret;
}


#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
static int lsapi_initLVE(void)
{
const char * pEnv;
Expand Down Expand Up @@ -1366,30 +1360,6 @@ static inline int lsapi_notify_pid( int fd )
return 0;
}


static char s_conn_key_packet[16];
static inline int init_conn_key( int fd )
{
struct lsapi_packet_header * pHeader = (struct lsapi_packet_header *)s_conn_key_packet;
struct timeval tv;
int i;
gettimeofday( &tv, NULL );
srand( (tv.tv_sec % 0x1000 + tv.tv_usec) ^ rand() );
for( i = 8; i < 16; ++i )
{
s_conn_key_packet[i]=(int) (256.0*rand()/(RAND_MAX+1.0));
}
lsapi_buildPacketHeader( pHeader, LSAPI_REQ_RECEIVED,
8 + LSAPI_PACKET_HEADER_LEN );
if ( write( fd, s_conn_key_packet, LSAPI_PACKET_HEADER_LEN+8 )
< LSAPI_PACKET_HEADER_LEN+8 )
return -1;
return 0;


}


static int readReq( LSAPI_Request * pReq )
{
int len;
Expand Down Expand Up @@ -3160,11 +3130,11 @@ static void lsapi_check_child_status( long tmCur )
//}


void set_skip_write()
void set_skip_write(void)
{ s_skip_write = 1; }


int is_enough_free_mem()
int is_enough_free_mem(void)
{
#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
//minimum 1GB or 10% available free memory
Expand Down Expand Up @@ -3832,7 +3802,7 @@ void LSAPI_No_Check_ppid(void)
}


int LSAPI_Get_ppid()
int LSAPI_Get_ppid(void)
{
return(s_ppid);
}
Expand Down
8 changes: 4 additions & 4 deletions sapi/litespeed/lscriu.c
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
static int s_initial_start_reqs = 0;
static int s_requests_count = 0;
static int s_restored = 0;
static int (*s_lscapi_dump_me)() = NULL;
static int (*s_lscapi_prepare_me)() = NULL;
static int (*s_lscapi_dump_me)(void) = NULL;
static int (*s_lscapi_prepare_me)(void) = NULL;
static int s_native = 0;
static int s_tried_checkpoint = 0;
static int s_criu_debug = 0;
Expand All @@ -118,7 +118,7 @@ typedef void (*sighandler_t)(int);

void lsapi_perror( const char * pMessage, int err_no );
void LSAPI_reset_server_state( void );
int LSAPI_Get_ppid();
int LSAPI_Get_ppid(void);

#ifdef LSAPILIB_DEBUG_CRIU
#define lscriu_dbg(...) \
Expand Down Expand Up @@ -541,7 +541,7 @@ static void LSCRIU_try_checkpoint(int *forked_pid)
}


static int init_native_env()
static int init_native_env(void)
{
char *pchFd;
pchFd = getenv("LSAPI_CRIU_SYNC_FD");
Expand Down