From f7d4c8891e5ef64d13567845b2bc02f31152c323 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Thu, 2 Apr 2020 13:01:08 +0200 Subject: Small fixes in the run executable The run script is now able to run from any location && exits when the installation test failed --- src/kernel/fs/elf.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/kernel/fs/elf.c') diff --git a/src/kernel/fs/elf.c b/src/kernel/fs/elf.c index 62c4e8d..9af3636 100644 --- a/src/kernel/fs/elf.c +++ b/src/kernel/fs/elf.c @@ -40,14 +40,12 @@ uint32_t load_elf(char *elf_data) v_begin = p_entry->vaddr; v_end = p_entry->vaddr + p_entry->memsz; if (v_begin < USER_OFFSET) { - warn("load_elf(): can't load executable below %x\n", - USER_OFFSET); + warn("load_elf(): can't load executable below %x\n", USER_OFFSET); return 0; } if (v_end > USER_STACK) { - warn("load_elf(): can't load executable above %x\n", - USER_STACK); + warn("load_elf(): can't load executable above %x\n", USER_STACK); return 0; } @@ -65,4 +63,4 @@ uint32_t load_elf(char *elf_data) } return hdr->entry; -} +} \ No newline at end of file -- cgit v1.2.3