X-Git-Url: http://git.joshuawise.com/netwatch.git/blobdiff_plain/d2fd2046a1a67ba4b01aab0ca68c790b02f9c93c..835f2e85092de1495d146530f1c3ca951ae84d61:/elfload/loader.c?ds=sidebyside diff --git a/elfload/loader.c b/elfload/loader.c index f5be3a4..c70571d 100644 --- a/elfload/loader.c +++ b/elfload/loader.c @@ -1,6 +1,6 @@ #include #include -#include "elf.h" +#include "../include/elf.h" #include #include #include @@ -73,7 +73,7 @@ int load_elf (char * buf) { char * section_name = string_table + elf_sec_hdrs[i].sh_name; - if (!(elf_sec_hdrs[i].sh_flags & SHF_ALLOC)) { + if ((elf_sec_hdrs[i].sh_type != SHT_PROGBITS) || !(elf_sec_hdrs[i].sh_flags & SHF_ALLOC)) { printf("Skipping %s...\n", section_name); continue; }