summaryrefslogtreecommitdiff
path: root/main/main.c
diff options
context:
space:
mode:
authorSVN Migration <svn@php.net>1999-07-24 21:40:38 +0000
committerSVN Migration <svn@php.net>1999-07-24 21:40:38 +0000
commitcd59acb4a010863d3e7ac4724acd5288bd25a7b7 (patch)
treef788796e74759b0c09c3032b1cd6da3fc98a49b3 /main/main.c
parentb1617d8ac3bad1ace92085194e24cff8cbdbaf31 (diff)
downloadphp-git-BEFORE_BIG_SYMBOL_CHANGE.tar.gz
This commit was manufactured by cvs2svn to create tagBEFORE_BIG_SYMBOL_CHANGE
'BEFORE_BIG_SYMBOL_CHANGE'.
Diffstat (limited to 'main/main.c')
-rw-r--r--main/main.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/main/main.c b/main/main.c
index 59d1a54b37..6c0db41cd9 100644
--- a/main/main.c
+++ b/main/main.c
@@ -359,6 +359,9 @@ PHPAPI void php3_error(int type, const char *format,...)
error_filename = zend_get_compiled_filename();
error_lineno = CG(zend_lineno);
+ if (!error_filename) {
+ error_filename = zend_get_executed_filename(ELS_C);
+ }
}
break;
case E_ERROR:
@@ -372,6 +375,10 @@ PHPAPI void php3_error(int type, const char *format,...)
error_lineno = 0;
break;
}
+
+ if (!error_filename) {
+ error_filename = "Unknown";
+ }
if (EG(error_reporting) & type || (type & E_CORE)) {
char *error_type_str;
@@ -768,11 +775,10 @@ int php_module_startup(sapi_module_struct *sf)
sapi_globals_struct *sapi_globals = ts_resource(sapi_globals_id);
#endif
#if (WIN32|WINNT) && !(USE_SAPI)
- WORD wVersionRequested;
+ WORD wVersionRequested = MAKEWORD(2, 0);
WSADATA wsaData;
-
- wVersionRequested = MAKEWORD(2, 0);
#endif
+ ELS_FETCH();
SG(server_context) = NULL;
SG(request_info).request_method = NULL;
@@ -782,6 +788,8 @@ int php_module_startup(sapi_module_struct *sf)
return SUCCESS;
}
+ EG(error_reporting) = E_ALL & ~E_NOTICE;
+
sapi_module = *sf;
zend_output_startup();