Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107462563
D30233.id89081.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
456 B
Referenced Files
None
Subscribers
None
D30233.id89081.diff
View Options
Index: sys/kern/kern_time.c
===================================================================
--- sys/kern/kern_time.c
+++ sys/kern/kern_time.c
@@ -1652,6 +1652,8 @@
if (ts->tv_sec < 0 || ts->tv_nsec < 0 || ts->tv_nsec >= 1000000000)
return (EINVAL);
+ if ((UINT64_MAX - ts->tv_nsec) / 1000000000 < ts->tv_sec)
+ return (EINVAL);
if (ts->tv_sec == 0 && ts->tv_nsec != 0 && ts->tv_nsec < tick * 1000)
ts->tv_nsec = tick * 1000;
return (0);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 15, 12:44 PM (9 h, 14 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15810710
Default Alt Text
D30233.id89081.diff (456 B)
Attached To
Mode
D30233: posix timers: Check for overflow when converting to ns
Attached
Detach File
Event Timeline
Log In to Comment