summaryrefslogtreecommitdiff
path: root/Zend/zend_ini_parser.y
diff options
context:
space:
mode:
authorAnatol Belski <ab@php.net>2014-12-03 16:33:05 +0100
committerAnatol Belski <ab@php.net>2014-12-03 16:33:05 +0100
commit65fce7f9504036c561a97168d7759e01755ae31d (patch)
treef0fa582c26f9b11c6b86dd7ab2f0bfd7d7c5b584 /Zend/zend_ini_parser.y
parent4d743eee5f01cfb5f93f05c85ed6d00dd4f7ba38 (diff)
downloadphp-git-65fce7f9504036c561a97168d7759e01755ae31d.tar.gz
Fixed bug #55541 errors spawn MessageBox, which blocks test automation
With that, also fixed bug #68297 (Application Popup provides too few information) as a better error message is provided to the event log. In the second case, the condition for display_startup_error was removed. The condition was added as a fix for bug #30760 which was preventing the MessageBox to appear. When display_startup_error=on, the error will be seen on the console. But when running under a webserver it'll probably get lost, so we need to log it other way into the event log (would be done automatically when message box was used, but that would eventually cause issues of blocked execution). Generally speaking - any MessageBox or other graphical element is a potential issue and that was repeatedly reported. Graphical elements shouldn't be used in the core. Even being a rare one it can cause a bad situation where the server is blocked. Yet some places have to cleaned up.
Diffstat (limited to 'Zend/zend_ini_parser.y')
-rw-r--r--Zend/zend_ini_parser.y9
1 files changed, 6 insertions, 3 deletions
diff --git a/Zend/zend_ini_parser.y b/Zend/zend_ini_parser.y
index 3823efd413..b56277b16a 100644
--- a/Zend/zend_ini_parser.y
+++ b/Zend/zend_ini_parser.y
@@ -29,6 +29,10 @@
#include "zend_ini_scanner.h"
#include "zend_extensions.h"
+#ifdef PHP_WIN32
+#include "win32/syslog.h"
+#endif
+
#define YYERROR_VERBOSE
#define YYSTYPE zval
@@ -179,10 +183,9 @@ static void ini_error(char *msg)
if (CG(ini_parser_unbuffered_errors)) {
#ifdef PHP_WIN32
- MessageBox(NULL, error_buf, "PHP Error", MB_OK|MB_TOPMOST|0x00200000L);
-#else
- fprintf(stderr, "PHP: %s", error_buf);
+ syslog(LOG_ALERT, "PHP: %s (%s)", error_buf, GetCommandLine());
#endif
+ fprintf(stderr, "PHP: %s", error_buf);
} else {
zend_error(E_WARNING, "%s", error_buf);
}