Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F34421954
ptimes-21M28.diff
gad (Garance A Drosehn)
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
gad
Dec 29 2021, 1:31 AM
2021-12-29 01:31:18 (UTC+0)
Size
441 B
Referenced Files
None
Subscribers
None
ptimes-21M28.diff
View Options
diff --git a/usr.sbin/newsyslog/ptimes.c b/usr.sbin/newsyslog/ptimes.c
index b7b993f01..d54ca1d40 100644
--- a/usr.sbin/newsyslog/ptimes.c
+++ b/usr.sbin/newsyslog/ptimes.c
@@ -279,6 +279,10 @@ parseDWM(struct ptime_data *ptime, const char *s)
if (tm.tm_mday > daysmon) {
tm.tm_mon++;
tm.tm_mday = tm.tm_mday - daysmon;
+ if (tm.tm_mon >= 12) {
+ tm.tm_mon = 0;
+ tm.tm_year++;
+ }
}
}
break;
File Metadata
Details
Attached
Mime Type
text/x-diff
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4369424
Default Alt Text
ptimes-21M28.diff (441 B)
Attached To
Mode
D33666: newsyslog: Wrap months when parsing 'W' rules.
Attached
Detach File
Event Timeline
Log In to Comment