From: Will Sowerbutts Date: Wed, 28 Dec 2016 17:26:06 +0000 (+0000) Subject: Kernel binman: fix off-by-one error, allowing COMMONMEM to use the last X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=06bb2113d9dee6a282fa596756941f6e28570969;p=FUZIX.git Kernel binman: fix off-by-one error, allowing COMMONMEM to use the last byte of RAM (at address 0xFFFF). --- diff --git a/Kernel/tools/binman.c b/Kernel/tools/binman.c index 72de486d..25dc4a18 100644 --- a/Kernel/tools/binman.c +++ b/Kernel/tools/binman.c @@ -109,9 +109,9 @@ int main(int argc, char *argv[]) ProcessMap(map); fclose(map); - if (s__COMMONMEM > 0xFFFF || s__COMMONMEM + l__COMMONMEM > 0xFFFF) { + if (s__COMMONMEM > 0xFFFF || s__COMMONMEM + l__COMMONMEM > 0x10000) { fprintf(stderr, "Move common down by at least %d bytes\n", - s__COMMONMEM + l__COMMONMEM - 0xFFFF); + s__COMMONMEM + l__COMMONMEM - 0x10000); exit(1); }