Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107332364
D47240.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
514 B
Referenced Files
None
Subscribers
None
D47240.diff
View Options
diff --git a/sys/kern/kern_linker.c b/sys/kern/kern_linker.c
--- a/sys/kern/kern_linker.c
+++ b/sys/kern/kern_linker.c
@@ -2030,6 +2030,10 @@
printf("linker.hints file too large %ld\n", (long)vattr.va_size);
goto bad;
}
+ if (vattr.va_size < sizeof(ival)) {
+ printf("linker.hints file truncated\n");
+ goto bad;
+ }
hints = malloc(vattr.va_size, M_TEMP, M_WAITOK);
error = vn_rdwr(UIO_READ, nd.ni_vp, (caddr_t)hints, vattr.va_size, 0,
UIO_SYSSPACE, IO_NODELOCKED, cred, NOCRED, &reclen, td);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jan 13, 3:06 PM (19 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14316039
Default Alt Text
D47240.diff (514 B)
Attached To
Mode
D47240: linker: Handle a truncated hints file properly
Attached
Detach File
Event Timeline
Log In to Comment