them sort based on the current locale. (Derick)
- Changed sha1_file() and md5_file() functions to use streams instead of
low level IO. (Uwe)
+- Fixed bug #33019 (socket errors cause memory leaks in php_strerror()).
+ (jwozniak23 at poczta dot onet dot pl, Tony).
- Fixed bug #32974 (pcntl calls malloc() from a signal handler). (Wez)
- Fixed bug #32936 (http redirects URLs are not checked for control chars). (Ilia)
- Fixed bug #32932 (Oracle LDAP: ldap_get_entries invalid pointer). (Jani)
buf = hstrerror(error);
#else
{
+ if (SOCKETS_G(strerror_buf)) {
+ efree(SOCKETS_G(strerror_buf));
+ }
+
spprintf(&(SOCKETS_G(strerror_buf)), 0, "Host lookup error %d", error);
buf = SOCKETS_G(strerror_buf);
}
if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
NULL, error, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR) &tmp, 0, NULL)) {
+
+ if (SOCKETS_G(strerror_buf)) {
+ efree(SOCKETS_G(strerror_buf));
+ }
+
SOCKETS_G(strerror_buf) = estrdup(tmp);
LocalFree(tmp);