|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-05-26 16:37 UTC] pajoye@php.net
[2011-05-26 16:37 UTC] pajoye@php.net
-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: pajoye
[2011-05-26 16:37 UTC] pajoye@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 20 21:00:02 2025 UTC |
Description: ------------ Under Windows if php fail to load an extension apache crash. Looking at code I discovered that php_win_err is wrong (I don't know if this fix my problem). In win32/winutil.c PHPAPI char *php_win_err(int error) { char *buf = NULL; FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, NULL, error, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR)&buf, 0, NULL ); return (buf ? (char *) buf : ""); } now if FormatMessage fails buf is NULL and a "" is returned however in ext/standard/dl.c a LocalFree is called if err (php_win_err result) is not NULL. Expected result: ---------------- Program should report error and not crash