File tree Expand file tree Collapse file tree 5 files changed +18
-7
lines changed
Expand file tree Collapse file tree 5 files changed +18
-7
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,9 @@ PHP NEWS
1616 . Fixed bug #78139 (timezone_open accepts invalid timezone string argument).
1717 (Derick)
1818
19+ - FPM:
20+ . Fixed bug #67764 (fpm: syslog.ident don't work). (Jakub Zelenka)
21+
1922- MBString:
2023 . Fixed bug GH-8685 (pcre not ready at mbstring startup). (Remi)
2124
Original file line number Diff line number Diff line change @@ -120,11 +120,6 @@ PHP_MSHUTDOWN_FUNCTION(syslog)
120120 return SUCCESS ;
121121}
122122
123- void php_openlog (const char * ident , int option , int facility )
124- {
125- openlog (ident , option , facility );
126- PG (have_called_openlog ) = 1 ;
127- }
128123
129124/* {{{ Open connection to system logger */
130125/*
@@ -161,7 +156,7 @@ PHP_FUNCTION(closelog)
161156{
162157 ZEND_PARSE_PARAMETERS_NONE ();
163158
164- closelog ();
159+ php_closelog ();
165160 if (BG (syslog_device )) {
166161 free (BG (syslog_device ));
167162 BG (syslog_device )= NULL ;
Original file line number Diff line number Diff line change 3232#define syslog std_syslog
3333#endif
3434
35+ void php_openlog (const char * ident , int option , int facility )
36+ {
37+ openlog (ident , option , facility );
38+ PG (have_called_openlog ) = 1 ;
39+ }
40+
41+ void php_closelog ()
42+ {
43+ closelog ();
44+ PG (have_called_openlog ) = 0 ;
45+ }
46+
3547#ifdef PHP_WIN32
3648PHPAPI void php_syslog (int priority , const char * format , ...) /* {{{ */
3749{
Original file line number Diff line number Diff line change 3737BEGIN_EXTERN_C ()
3838PHPAPI void php_syslog (int , const char * format , ...);
3939PHPAPI void php_openlog (const char * , int , int );
40+ PHPAPI void php_closelog ();
4041END_EXTERN_C ()
4142
4243#endif
Original file line number Diff line number Diff line change @@ -88,7 +88,7 @@ int fpm_stdio_init_child(struct fpm_worker_pool_s *wp) /* {{{ */
8888{
8989#ifdef HAVE_SYSLOG_H
9090 if (fpm_globals .error_log_fd == ZLOG_SYSLOG ) {
91- closelog (); /* ensure to close syslog not to interrupt with PHP syslog code */
91+ php_closelog (); /* ensure to close syslog not to interrupt with PHP syslog code */
9292 } else
9393#endif
9494
You can’t perform that action at this time.
0 commit comments