--- php-8.4.6.old/main/SAPI.c +++ php-8.4.6/main/SAPI.c @@ -17,6 +17,7 @@ */ #include +#include #include #include @@ -76,6 +77,11 @@ _configthreadlocale(_ENABLE_PER_THREAD_LOCALE); # endif #else + { // Workaround for a bizarre problem + FILE *kludge = popen ("/bin/true", "r"); + if (kludge != NULL) pclose (kludge); + } + sapi_globals_ctor(&sapi_globals); #endif --- php-8.4.6.old/TSRM/TSRM.c +++ php-8.4.6/TSRM/TSRM.c @@ -118,6 +118,10 @@ /* Startup TSRM (call once for the entire process) */ TSRM_API bool tsrm_startup(int expected_threads, int expected_resources, int debug_level, const char *debug_filename) {/*{{{*/ + { // Workaround for a bizarre problem + FILE *kludge = popen ("/bin/true", "r"); + if (kludge != NULL) pclose (kludge); + } #ifdef TSRM_WIN32 tls_key = TlsAlloc(); #else