aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mkelf.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/mkelf.lua b/mkelf.lua
index 2f811a3..eb4c67b 100644
--- a/mkelf.lua
+++ b/mkelf.lua
@@ -96,6 +96,7 @@ local function main()
i = i + 1
end
local header, segments, sections = loadconfig(infn)
+ if next(header) == nil then die("header missing") end
if header.phnum == 0 then header.phnum = #segments end
if header.shnum == 0 then header.shnum = #sections end
local out <close> = assert(io.open(outfn, "wb"))