From 43d0bb8e3997022e5270f7f75f615a47819c929e Mon Sep 17 00:00:00 2001 From: Alex AUVOLAT Date: Tue, 1 May 2012 23:48:56 +0200 Subject: Basic object system - THIS IS STILL A LONG WAY TO GO!! --- src/kernel/linker/elf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/kernel/linker') diff --git a/src/kernel/linker/elf.c b/src/kernel/linker/elf.c index af6d057..fa8d179 100644 --- a/src/kernel/linker/elf.c +++ b/src/kernel/linker/elf.c @@ -27,7 +27,7 @@ thread_entry elf_load(uint8_t *data, struct process* process) { seg_map(simpleseg_make(phdr[i].p_vaddr, phdr[i].p_memsz, (phdr[i].p_flags & PF_W) != 0), process->pagedir, 0); memcpy((uint8_t*)phdr[i].p_vaddr, data + phdr[i].p_offset, phdr[i].p_filesz); if (phdr[i].p_memsz > phdr[i].p_filesz) { - memset((uint8_t*)phdr[i].p_vaddr + phdr[i].p_memsz, 0, phdr[i].p_memsz - phdr[i].p_filesz); + memset((uint8_t*)phdr[i].p_vaddr + phdr[i].p_filesz, 0, phdr[i].p_memsz - phdr[i].p_filesz); } if (phdr[i].p_vaddr + phdr[i].p_memsz > dataseg) { dataseg = phdr[i].p_vaddr + phdr[i].p_memsz; -- cgit v1.2.3