Date: Sun, 06 Sep 2015 16:51:40 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-ports-bugs@FreeBSD.org Subject: [Bug 202932] sysutils/rsyslog8 endless loop on FreeBSD 10.2 Message-ID: <bug-202932-13@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=202932 Bug ID: 202932 Summary: sysutils/rsyslog8 endless loop on FreeBSD 10.2 Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Many People Priority: --- Component: Individual Port(s) Assignee: brd@FreeBSD.org Reporter: fbsd.bugzilla@fenyo.net Flags: maintainer-feedback?(brd@FreeBSD.org) Assignee: brd@FreeBSD.org Created attachment 160781 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=160781&action=edit correcting the endless loop bug Hi, Bug ID 200429 (endless loop when started at boot time), that had been corrected on FreeBSD 10.1, came back with FreeBSD 10.2, due to kernel behaviour changes. When the /dev/console device is revoked, writing to the device sets errno to: - ENXIO with FreeBSD 10.1 kernel - EIO with FreeBSD 10.2 kernel The following program can be used to see this behaviour change: ------------------------------------------------------------------ #include <stdio.h> #include <sys/types.h> #include <unistd.h> #include <fcntl.h> extern int errno; int main() { int id = open("/dev/console", O_RDWR); revoke("/dev/console"); int ret = write(id, "X", 1); if (ret < 0) printf("errno=%d\n", errno); return 0; } ------------------------------------------------------------------ It returns 6 (ENXIO) on FreeBSD 10.1 and 5 (EIO) on FreeBSD 10.2. To make rsyslog8 work correctly, here is a new version of sysutils/rsyslog8/files/patch-runtime_stream.c, in which I've added modifications to correct the bug. Note that the bug had been previously corrected in the main stream, in the rsyslog8 original sources, not by a FreeBSD patch. But I've not sent a patch proposal to the main stream this time because I suspect that the new behaviour of the kernel is unwanted. So, I will open a bug report for this new behaviour, and depending on the result, I may, or not, send back a bug report to the main stream. Sincerely, -- You are receiving this mail because: You are the assignee for the bug.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-202932-13>