1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-11-26 09:07:38 +01:00

(get_kernel_table): Use sos_alloc()/sos_free() instead of malloc()/free().

(Logical change 1.19)
This commit is contained in:
mostang.com!davidm 2002-07-18 03:58:34 +00:00
parent 9ac7c9cda2
commit e3cb03d7b6

View file

@ -73,7 +73,7 @@ get_kernel_table (void *ptr)
debug (100, "unwind: checking kernel unwind table"); debug (100, "unwind: checking kernel unwind table");
size = getunwind (NULL, 0); size = getunwind (NULL, 0);
ktab = malloc (size); ktab = sos_alloc (size);
if (!ktab) if (!ktab)
{ {
dprintf (__FILE__".%s: failed to allocate %Zu bytes", dprintf (__FILE__".%s: failed to allocate %Zu bytes",
@ -88,7 +88,7 @@ get_kernel_table (void *ptr)
if (info->segbase < ktab[0].start_offset if (info->segbase < ktab[0].start_offset
|| info->segbase >= etab[-1].end_offset) || info->segbase >= etab[-1].end_offset)
{ {
free (ktab); sos_free (ktab);
return -1; return -1;
} }