X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=pico%2Fcart.c;h=8ac330ad56cd4d839df16dfb4d2886d563fcaef1;hb=b4db550e41b2aa277f570d7bff890c8e8ee1831f;hp=fa283c8de0f5e0b4dcaa4947bba065a09b00f946;hpb=a736af3ecf708652f90e9cb05445d984960a0eec;p=picodrive.git diff --git a/pico/cart.c b/pico/cart.c index fa283c8..8ac330a 100644 --- a/pico/cart.c +++ b/pico/cart.c @@ -439,6 +439,9 @@ static unsigned char *PicoCartAlloc(int filesize, int is_sms) if (filesize > (1 << s)) s++; rom_alloc_size = 1 << s; + // be sure we can cover all address space + if (rom_alloc_size < 0x10000) + rom_alloc_size = 0x10000; } else { // make alloc size at least sizeof(mcd_state),