diff options
author | Alexis211 <alexis211@gmail.com> | 2009-10-18 12:35:07 +0200 |
---|---|---|
committer | Alexis211 <alexis211@gmail.com> | 2009-10-18 12:35:07 +0200 |
commit | bc2eccdd11c27029096fb3e891073503eb269e27 (patch) | |
tree | 555c2a56c810af5a292dbe270ad9c12dc0f17993 /Source/Kernel/Linker/Binary.proto.cpp | |
parent | 22c06556ccbd07f4ef7da39a62d10e03fbee3fe0 (diff) | |
download | Melon-bc2eccdd11c27029096fb3e891073503eb269e27.tar.gz Melon-bc2eccdd11c27029096fb3e891073503eb269e27.zip |
We can now load ELF binaries !!!
Diffstat (limited to 'Source/Kernel/Linker/Binary.proto.cpp')
-rw-r--r-- | Source/Kernel/Linker/Binary.proto.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/Kernel/Linker/Binary.proto.cpp b/Source/Kernel/Linker/Binary.proto.cpp index 6053f22..c0345da 100644 --- a/Source/Kernel/Linker/Binary.proto.cpp +++ b/Source/Kernel/Linker/Binary.proto.cpp @@ -1,16 +1,18 @@ #include "Binary.proto.h" #include <Linker/MelonBinary.class.h> +#include <Linker/ElfBinary.class.h> Binary* (*loaders[])(File& file) = { &MelonBinary::load, - + &ElfBinary::load, 0 }; Binary* Binary::load(File& file) { Binary* r = 0; u32int i = 0; while (loaders[i] != 0) { + file.seek(0, SM_BEGINNING); r = loaders[i](file); //Call loader if (r != 0) break; i++; |