| Summary: | syslogd: fix re-opening log files after deleting or moving them | ||
|---|---|---|---|
| Product: | Busybox | Reporter: | Christoph Schulz <develop> |
| Component: | Other | Assignee: | unassigned |
| Status: | NEW --- | ||
| Severity: | minor | CC: | busybox-cvs |
| Priority: | P5 | ||
| Version: | 1.22.x | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Host: | Target: | ||
| Build: | |||
| Attachments: | fix re-opening log files after deleting or moving them | ||
Created attachment 5636 [details] fix re-opening log files after deleting or moving them With the patch attached, syslogd correctly re-opens log files. The current code uses one global last-logged timestamp for all log targets. If a message is to be logged to multiple log files, the global last-logged timestamp is compared to the current system time. If there is a difference of at least one second, the log file is re-opened and the timestamp is updated. However, because of the timestamp update, all subsequent log files are _not_ re-opened even if they need to. The patch attached uses a per-log-target timestamp to overcome this bug.