mirror of
https://github.com/php/php-src.git
synced 2026-03-27 01:32:22 +01:00
- Fix #51424, crypt() function hangs after 3rd call
This commit is contained in:
1
NEWS
1
NEWS
@@ -141,6 +141,7 @@ PHP NEWS
|
||||
- Fixed bug #51445 (var_dump() invalid/slow *RECURSION* detection). (Felipe)
|
||||
- Fixed bug #51435 (Missing ifdefs / logic bug in crypt code cause compile
|
||||
errors). (Felipe)
|
||||
- Fixed bug #51424 (crypt() function hangs after 3rd call). (Pierre)
|
||||
- Fixed bug #51394 (Error line reported incorrectly if error handler throws an
|
||||
exception). (Stas)
|
||||
- Fixed bug #51393 (DateTime::createFromFormat() fails if format string contains
|
||||
|
||||
@@ -81,11 +81,13 @@ void _crypt_extended_init_r(void)
|
||||
tsrm_mutex_lock(php_crypt_extended_init_lock);
|
||||
#endif
|
||||
|
||||
if (initialized) {
|
||||
return;
|
||||
} else {
|
||||
if (!initialized) {
|
||||
#ifdef PHP_WIN32
|
||||
InterlockedIncrement(initialized);
|
||||
#elif (defined(__GNUC__) && (__GNUC__ >= 4 && __GNUC_MINOR >= 2))
|
||||
__sync_fetch_and_add(&initialized, 1);
|
||||
#endif
|
||||
_crypt_extended_init();
|
||||
initialized = 1;
|
||||
}
|
||||
#ifdef ZTS
|
||||
tsrm_mutex_unlock(php_crypt_extended_init_lock);
|
||||
|
||||
Reference in New Issue
Block a user