Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F154213972
D53502.id165673.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
852 B
Referenced Files
None
Subscribers
None
D53502.id165673.diff
View Options
diff --git a/contrib/tzcode/localtime.c b/contrib/tzcode/localtime.c
--- a/contrib/tzcode/localtime.c
+++ b/contrib/tzcode/localtime.c
@@ -1583,15 +1583,15 @@
struct timespec now;
if (clock_gettime(CLOCK_MONOTONIC, &now) < 0)
- return 0;
+ return 1;
- if ((now.tv_sec - last_checked >= __tz_change_interval) ||
- (last_checked > now.tv_sec)) {
+ if (last_checked == 0 || last_checked > now.tv_sec ||
+ now.tv_sec - last_checked >= __tz_change_interval) {
last_checked = now.tv_sec;
- return 1;
+ return 0;
}
- return 0;
+ return 1;
}
#endif /* DETECT_TZ_CHANGES */
@@ -1642,7 +1642,7 @@
? lcl_is_set < 0
: 0 < lcl_is_set && strcmp(lcl_TZname, name) == 0)
#ifdef DETECT_TZ_CHANGES
- if (tzdata_is_fresh() == 0)
+ if (tzdata_is_fresh())
#endif /* DETECT_TZ_CHANGES */
return;
# ifdef ALL_STATE
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Apr 28, 4:23 AM (7 h, 37 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
32250464
Default Alt Text
D53502.id165673.diff (852 B)
Attached To
Mode
D53502: tzcode: Fix early tz change detection
Attached
Detach File
Event Timeline
Log In to Comment