aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/link_elf.c
diff options
context:
space:
mode:
authorKonstantin Belousov <kib@FreeBSD.org>2012-02-21 01:05:12 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2012-02-21 01:05:12 +0000
commit526d0bd547574b185147f03c13e2db7abe566a08 (patch)
treed0d078391c4959fc08545db4ab619daadd9cf1d9 /sys/kern/link_elf.c
parent57a82ba4d95159d3623b0d401cfc3cc8f6357c28 (diff)
downloadsrc-526d0bd547574b185147f03c13e2db7abe566a08.tar.gz
src-526d0bd547574b185147f03c13e2db7abe566a08.zip
Fix found places where uio_resid is truncated to int.
Add the sysctl debug.iosize_max_clamp, enabled by default. Setting the sysctl to zero allows to perform the SSIZE_MAX-sized i/o requests from the usermode. Discussed with: bde, das (previous versions) MFC after: 1 month
Notes
Notes: svn path=/head/; revision=231949
Diffstat (limited to 'sys/kern/link_elf.c')
-rw-r--r--sys/kern/link_elf.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/link_elf.c b/sys/kern/link_elf.c
index 2f9a1f685662..5dd0623cdc40 100644
--- a/sys/kern/link_elf.c
+++ b/sys/kern/link_elf.c
@@ -655,7 +655,8 @@ link_elf_load_file(linker_class_t cls, const char* filename,
Elf_Addr base_vaddr;
Elf_Addr base_vlimit;
int error = 0;
- int resid, flags;
+ ssize_t resid;
+ int flags;
elf_file_t ef;
linker_file_t lf;
Elf_Shdr *shdr;