Remove unused SmartHeap class

This commit is contained in:
EnderIce2
2024-08-13 07:37:20 +03:00
parent e2e9cfe84d
commit 31dca2e9a6
5 changed files with 22 additions and 111 deletions

View File

@ -1758,8 +1758,8 @@ static int linux_uname(SysFrm *, struct utsname *buf)
};
rn->Stat(&st);
Memory::SmartHeap sh = Memory::SmartHeap(st.Size);
rn->Read(sh.Get(), st.Size, 0);
char *sh = new char[st.Size];
rn->Read(sh, st.Size, 0);
ini_t *ini = ini_load(sh, NULL);
int section = ini_find_section(ini, "uname", NULL);
@ -1790,6 +1790,8 @@ static int linux_uname(SysFrm *, struct utsname *buf)
if (uMac && strcmp(uMac, "auto") != 0)
strncpy(uname.machine, uMac, sizeof(uname.machine));
ini_destroy(ini);
delete[] sh;
}
else
warn("Couldn't open /etc/cross/linux");