Bug #77913 [Asn->Csd]: error_log via syslog: PHP will split msg on line break

From: Date: Mon, 17 Jun 2019 11:17:21 +0000
Subject: Bug #77913 [Asn->Csd]: error_log via syslog: PHP will split msg on line break
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-221343@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=77913&edit=1 ID: 77913 Updated by: nikic@php.net Reported by: whissi at whissi dot de Summary: error_log via syslog: PHP will split msg on line break -Status: Assigned +Status: Closed Type: Bug Package: *General Issues PHP Version: 7.3.4 Assigned To: ab Block user comment: N Private report: N New Comment: https://github.com/php/php-src/pull/4265 adds a new syslog.filter=raw option to not process syslog messages at all -- newlines will be passed through as is. Previous Comments: ------------------------------------------------------------------------ [2019-04-16 22:30:41] spam2 at rhsoft dot net > I think the newline treatment is a good thing and probably > what the average developer would expect to happen for sure not, i would expect and code that in a away that the new line is replaced by a space because grep and friends don't work very nice with magically wrapped lines ------------------------------------------------------------------------ [2019-04-16 21:42:41] requinix@php.net https://github.com/php/php-src/commit/a1f3a0105d885879102d366de506c353a75c8d04 I think the newline treatment is a good thing and probably what the average developer would expect to happen, BC break or not, so IMO this should be a doc bug. ------------------------------------------------------------------------ [2019-04-16 19:49:17] whissi at whissi dot de And if this was a desired change, maybe rename "syslog.filter=no-ctrl" to "syslog.filter=no-ctrl-but-line-breaks" :-) I.e. you either _filter_ all ctrl chars like the option says or none. But filtering some but handle/interpret others isn't good. ------------------------------------------------------------------------ [2019-04-16 19:43:40] whissi at whissi dot de Not when this is a backward incompatible change. Of course, if this was a desired change, please add it to https://www.php.net/manual/en/migration73.incompatible.php and in addition please provide a way to send multi-line messages. ------------------------------------------------------------------------ [2019-04-16 19:36:08] requinix@php.net Isn't it a good thing that the line break is being recognized and handled? ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=77913 -- Edit this bug report at https://bugs.php.net/bug.php?id=77913&edit=1

« previous php.bugs (#221343) next »