Stop LeakSanitizer complaining about Uxn's RAM.
This commit is contained in:
parent
9024963de1
commit
f48a09c482
|
@ -133,13 +133,16 @@ load(Uxn *u, char *filepath)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static Uint8 *memory;
|
||||
|
||||
int
|
||||
main(int argc, char **argv)
|
||||
{
|
||||
Uxn u;
|
||||
int i, loaded = 0;
|
||||
|
||||
if(!uxn_boot(&u, (Uint8 *)calloc(0xffff, sizeof(Uint8))))
|
||||
memory = (Uint8 *)calloc(0xffff, sizeof(Uint8));
|
||||
if(!uxn_boot(&u, memory))
|
||||
return error("Boot", "Failed");
|
||||
|
||||
/* system */ devsystem = uxn_port(&u, 0x0, system_dei, system_deo);
|
||||
|
|
|
@ -271,10 +271,12 @@ load(Uxn *u, char *rom)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static Uint8 *memory;
|
||||
|
||||
static int
|
||||
start(Uxn *u, char *rom)
|
||||
{
|
||||
Uint8 *memory = (Uint8 *)calloc(0xffff, sizeof(Uint8));
|
||||
memory = (Uint8 *)calloc(0xffff, sizeof(Uint8));
|
||||
if(!uxn_boot(u, memory))
|
||||
return error("Boot", "Failed to start uxn.");
|
||||
if(!load(u, rom))
|
||||
|
|
Loading…
Reference in New Issue