tcc_realloc: auto "memory full" error
This commit is contained in:
2
tccelf.c
2
tccelf.c
@ -836,8 +836,6 @@ static void put_got_offset(TCCState *s1, int index, unsigned long val)
|
||||
while (index >= n)
|
||||
n *= 2;
|
||||
tab = tcc_realloc(s1->got_offsets, n * sizeof(unsigned long));
|
||||
if (!tab)
|
||||
tcc_error("memory full");
|
||||
s1->got_offsets = tab;
|
||||
memset(s1->got_offsets + s1->nb_got_offsets, 0,
|
||||
(n - s1->nb_got_offsets) * sizeof(unsigned long));
|
||||
|
||||
Reference in New Issue
Block a user