mirror of
https://github.com/php/php-src.git
synced 2024-11-24 10:24:11 +08:00
- Fixed wrong value of log_level when invoking fpm with -tt
This commit is contained in:
parent
987c843674
commit
c4b7abb4ea
1
NEWS
1
NEWS
@ -34,6 +34,7 @@ PHP NEWS
|
||||
. Fixed missing Expires and Cache-Control headers for ping and status pages.
|
||||
(fat)
|
||||
. Fixed memory leak. (fat) Reported and fixed by Giovanni Giacobbi.
|
||||
. Fixed wrong value of log_level when invoking fpm with -tt. (fat)
|
||||
|
||||
- SPL extension:
|
||||
. Fixed bug #54971 (Wrong result when using iterator_to_array with use_keys
|
||||
|
@ -1151,7 +1151,7 @@ static void fpm_conf_dump() /* {{{ */
|
||||
zlog(ZLOG_NOTICE, "\tpid = %s", STR2STR(fpm_global_config.pid_file));
|
||||
zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize));
|
||||
zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log));
|
||||
zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name());
|
||||
zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name(fpm_globals.log_level));
|
||||
zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout);
|
||||
zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval);
|
||||
zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold);
|
||||
|
@ -29,9 +29,15 @@ static const char *level_names[] = {
|
||||
[ZLOG_ALERT] = "ALERT",
|
||||
};
|
||||
|
||||
const char *zlog_get_level_name() /* {{{ */
|
||||
const char *zlog_get_level_name(int log_level) /* {{{ */
|
||||
{
|
||||
return level_names[zlog_level];
|
||||
if (log_level < 0) {
|
||||
log_level = zlog_level;
|
||||
} else if (log_level < ZLOG_DEBUG || log_level > ZLOG_ALERT) {
|
||||
return "unknown value";
|
||||
}
|
||||
|
||||
return level_names[log_level];
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
@ -11,7 +11,7 @@ struct timeval;
|
||||
|
||||
int zlog_set_fd(int new_fd);
|
||||
int zlog_set_level(int new_value);
|
||||
const char *zlog_get_level_name();
|
||||
const char *zlog_get_level_name(int log_level);
|
||||
void zlog_set_launched(void);
|
||||
|
||||
size_t zlog_print_time(struct timeval *tv, char *timebuf, size_t timebuf_len);
|
||||
|
Loading…
Reference in New Issue
Block a user