Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F144561223
D44285.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
538 B
Referenced Files
None
Subscribers
None
D44285.diff
View Options
diff --git a/stand/kboot/kboot/hostfs.c b/stand/kboot/kboot/hostfs.c
--- a/stand/kboot/kboot/hostfs.c
+++ b/stand/kboot/kboot/hostfs.c
@@ -133,8 +133,9 @@
* from V7 later ISO-C). Also assumes we have to support powerpc still,
* it's interface is weird for legacy reasons....
*/
- offl = offset & 0xffffffff;
- offh = (offset >> 32) & 0xffffffff;
+ res = (uint64_t)offset;
+ offl = res & 0xfffffffful;
+ offh = (res >> 32) & 0xfffffffful;
err = host_llseek(hf->hf_fd, offh, offl, &res, whence);
if (err < 0)
return (err);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Feb 10, 2:34 PM (7 h, 20 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28626477
Default Alt Text
D44285.diff (538 B)
Attached To
Mode
D44285: kboot: Avoid UB behavior
Attached
Detach File
Event Timeline
Log In to Comment