--- uae/src/memory.c 2018/04/24 16:43:32 1.1.1.5 +++ uae/src/memory.c 2018/04/24 16:44:54 1.1.1.6 @@ -505,16 +505,16 @@ static int load_kickstart (void) uae_u32 cksum = 0, prevck = 0; unsigned char buffer[20]; - FILE *f = zfile_open(romfile, "rb"); + FILE *f = zfile_open (currprefs.romfile, "rb"); if (f == NULL) { write_log ("No Kickstart ROM found.\n"); -#if defined(AMIGA)||defined(__POS__) +#if defined AMIGA || defined __POS__ #define USE_UAE_ERSATZ "USE_UAE_ERSATZ" - if (!getenv(USE_UAE_ERSATZ)) { - fprintf (stderr, "Using current ROM. (create ENV:%s to " - "use uae's ROM replacement)\n",USE_UAE_ERSATZ); - memcpy(kickmemory,(char*)0x1000000 - kickmem_size, kickmem_size); + if (!getenv (USE_UAE_ERSATZ)) { + fprintf (stderr, "Using current ROM. (create ENV:%s to " + "use uae's ROM replacement)\n", USE_UAE_ERSATZ); + memcpy (kickmemory, (char*)0x1000000 - kickmem_size, kickmem_size); goto chk_sum; } #endif @@ -542,11 +542,11 @@ static int load_kickstart (void) cloanto_rom = 1; write_log ("ROM image is an encrypted \"Amiga Forever\" ROM file.\n"); - if (strlen (keyfile) == 0) { + if (strlen (currprefs.keyfile) == 0) { write_log ("No filename given for ROM key file.\n"); return 0; } - keyf = zfile_open (keyfile, "rb"); + keyf = zfile_open (currprefs.keyfile, "rb"); if (keyf == 0) { write_log ("Could not find ROM key file.\n"); return 0; @@ -687,8 +687,8 @@ void memory_init (void) abort (); } #endif - - do_put_mem_long (chipmemory + 4, 0); + + do_put_mem_long ((uae_u32 *)(chipmemory + 4), 0); init_mem_banks (); /* Map the chipmem into all of the lower 16MB */