mirror of
https://github.com/gbdev/rgbds.git
synced 2026-09-22 21:57:07 +00:00
Fix to actually allow one-past-the-end zero-sized sections in linker scripts
This commit is contained in:
+1
-1
@@ -92,7 +92,7 @@ void layout_SetAddr(uint32_t addr) {
|
||||
|
||||
if (uint16_t &pc = curAddr[activeType][activeBankIdx]; addr < pc) {
|
||||
scriptError("Cannot decrease the current address (from $%04x to $%04x)", pc, addr);
|
||||
} else if (addr > typeInfo.endAddr()) { // Allow "one past the end" sections.
|
||||
} else if (addr > typeInfo.endAddr() + 1u) { // Allow "one past the end" zero-sized sections.
|
||||
scriptError(
|
||||
"Cannot set the current address to $%04" PRIx32 ": %s ends at $%04" PRIx16,
|
||||
addr,
|
||||
|
||||
Reference in New Issue
Block a user