mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-26 23:02:39 +02:00
Why is this not crashing
This commit is contained in:
parent
368fbbb570
commit
b877e1b1c1
@ -77,10 +77,6 @@ Result tmemClose(TransferMemory* t)
|
||||
{
|
||||
Result rc = 0;
|
||||
|
||||
if (t->src_addr != NULL) {
|
||||
free(t->src_addr);
|
||||
}
|
||||
|
||||
if (t->map_addr != NULL) {
|
||||
rc = tmemUnmap(t);
|
||||
}
|
||||
@ -90,6 +86,10 @@ Result tmemClose(TransferMemory* t)
|
||||
rc = svcCloseHandle(t->handle);
|
||||
}
|
||||
|
||||
if (t->src_addr != NULL) {
|
||||
free(t->src_addr);
|
||||
}
|
||||
|
||||
t->src_addr = NULL;
|
||||
t->handle = INVALID_HANDLE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user