Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F102059056
D41370.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
673 B
Referenced Files
None
Subscribers
None
D41370.diff
View Options
diff --git a/usr.sbin/syslogd/syslogd.c b/usr.sbin/syslogd/syslogd.c
--- a/usr.sbin/syslogd/syslogd.c
+++ b/usr.sbin/syslogd/syslogd.c
@@ -2575,7 +2575,10 @@
* Close all open log files.
*/
Initialized = false;
- STAILQ_FOREACH(f, &fhead, next) {
+ while (!STAILQ_EMPTY(&fhead)) {
+ f = STAILQ_FIRST(&fhead);
+ STAILQ_REMOVE_HEAD(&fhead, next);
+
/* flush any pending output */
if (f->f_prevcount)
fprintlog_successive(f, 0);
@@ -2593,10 +2596,7 @@
default:
break;
}
- }
- while(!STAILQ_EMPTY(&fhead)) {
- f = STAILQ_FIRST(&fhead);
- STAILQ_REMOVE_HEAD(&fhead, next);
+
free(f->f_program);
free(f->f_host);
if (f->f_prop_filter) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 8, 2:49 AM (21 h, 14 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14526079
Default Alt Text
D41370.diff (673 B)
Attached To
Mode
D41370: syslogd: Merge loops
Attached
Detach File
Event Timeline
Log In to Comment