File tree Expand file tree Collapse file tree 3 files changed +20
-3
lines changed
Expand file tree Collapse file tree 3 files changed +20
-3
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,9 @@ PHP NEWS
3838 . Fixed bug GH-12936 (hash() function hangs endlessly if using sha512 on
3939 strings >= 4GiB). (nielsdos)
4040
41+ - ODBC:
42+ . Fix crash on Apache shutdown with persistent connections. (nielsdos)
43+
4144- Opcache:
4245 . Fixed oss-fuzz #64727 (JIT undefined array key warning may overwrite DIM
4346 with NULL when DIM is the same var as result). (ilutov)
@@ -58,6 +61,8 @@ PHP NEWS
5861
5962- PGSQL:
6063 . Fixed auto_reset_persistent handling and allow_persistent type. (David Carlier)
64+ . Fixed bug GH-12974 (Apache crashes on shutdown when using pg_pconnect()).
65+ (nielsdos)
6166
6267- PHPDBG:
6368 . Fixed bug GH-12962 (Double free of init_file in phpdbg_prompt.c). (nielsdos)
Original file line number Diff line number Diff line change @@ -168,7 +168,13 @@ static void _close_odbc_conn(zend_resource *rsrc)
168168 SQLFreeEnv (conn -> henv );
169169 }
170170 efree (conn );
171- ODBCG (num_links )-- ;
171+ /* See https://github.com/php/php-src/issues/12974 why we need to check the if */
172+ #ifdef ZTS
173+ if (odbc_module_entry .module_started )
174+ #endif
175+ {
176+ ODBCG (num_links )-- ;
177+ }
172178}
173179/* }}} */
174180
Original file line number Diff line number Diff line change @@ -315,8 +315,14 @@ static void _close_pgsql_plink(zend_resource *rsrc)
315315 PQclear (res );
316316 }
317317 PQfinish (link );
318- PGG (num_persistent )-- ;
319- PGG (num_links )-- ;
318+ /* See https://github.com/php/php-src/issues/12974 why we need to check the if */
319+ #ifdef ZTS
320+ if (pgsql_module_entry .module_started )
321+ #endif
322+ {
323+ PGG (num_persistent )-- ;
324+ PGG (num_links )-- ;
325+ }
320326 rsrc -> ptr = NULL ;
321327}
322328
You can’t perform that action at this time.
0 commit comments