made the code cleaner

This commit is contained in:
2026-02-16 13:59:34 +01:00
parent b69b424ebe
commit b884dfd270

View File

@@ -49,7 +49,7 @@ local function getBootCode(addr)
local codeEnd = sectorSize - 66 local codeEnd = sectorSize - 66
local codeSec = string.sub(firstSector, 1, codeEnd) local codeSec = string.sub(firstSector, 1, codeEnd)
local term = string.find(codeSec, "\0", 5, true) local term = string.find(codeSec, "\0", 5, true)
return load(string.sub(codeSec, 0, term and (term - 1) or -1)) return load(string.sub(codeSec, 1, term and (term - 1) or -1))
end end
-- TODO: whatever else NC might be testing -- TODO: whatever else NC might be testing
local sectorsIn32K = math.ceil(32768 / sectorSize) local sectorsIn32K = math.ceil(32768 / sectorSize)