chore: fix almost *ALL* warnings.
[lunaix-os.git] / lunaix-os / kernel / exe / elf32 / elf32bfmt.c
index 1079b06f85d12e0437a02b9a13a447bc4ae401b6..451c3946bd915dd23b5d0eaa631c092901f50a92 100644 (file)
@@ -32,7 +32,7 @@ elf32_open(struct elf32* elf, const char* path)
 }
 
 int
-elf32_openat(struct elf32* elf, void* elf_vfile)
+elf32_openat(struct elf32* elf, const void* elf_vfile)
 {
     int status = 0;
     elf->pheaders = NULL;
@@ -166,7 +166,7 @@ elf32_read_phdr(struct elf32* elf)
 int
 elf32_check_exec(const struct elf32* elf)
 {
-    struct elf32_ehdr* ehdr = &elf->eheader;
+    const struct elf32_ehdr* ehdr = &elf->eheader;
 
     return *(u32_t*)(ehdr->e_ident) == ELFMAGIC &&
            ehdr->e_ident[EI_CLASS] == ELFCLASS32 &&