From 95b64737b7f4cb499936bd0af68d59f0de68fbdb Mon Sep 17 00:00:00 2001 From: mp Date: Sat, 18 Aug 2001 04:24:30 +0000 Subject: Unbreak linux compatibility by providing the correct length of the buffer. Reported by: "Pierre Y. Dampure" , "Niels Chr. Bank-Pedersen" Pointy hat to: mp --- sys/kern/imgact_elf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys/kern/imgact_elf.c') diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c index f503bf5..96aeafd 100644 --- a/sys/kern/imgact_elf.c +++ b/sys/kern/imgact_elf.c @@ -644,7 +644,7 @@ exec_elf_imgact(struct image_params *imgp) imgp->proc->p_sysent = brand_info->sysvec; if (interp != NULL) { path = malloc(MAXPATHLEN, M_TEMP, M_WAITOK); - snprintf(path, sizeof(path), "%s%s", + snprintf(path, MAXPATHLEN, "%s%s", brand_info->emul_path, interp); if ((error = elf_load_file(imgp->proc, path, &addr, &imgp->entry_addr)) != 0) { -- cgit v1.1