diff options
| author | grischka <grischka> | 2012-04-18 18:43:55 +0200 |
|---|---|---|
| committer | grischka <grischka> | 2012-04-18 18:43:55 +0200 |
| commit | f1b5c2ef4fc1d43c5a73e15854d094e9219857bf (patch) | |
| tree | 00d881305eb5b6b96544047bac495072f5e527a2 /tccpp.c | |
| parent | 3c59f8424048fdc2f7b7ce8d840351ef2fb212b4 (diff) | |
| download | tinycc-f1b5c2ef4fc1d43c5a73e15854d094e9219857bf.tar.gz tinycc-f1b5c2ef4fc1d43c5a73e15854d094e9219857bf.tar.bz2 | |
tcc_realloc: auto "memory full" error
Diffstat (limited to 'tccpp.c')
| -rw-r--r-- | tccpp.c | 6 |
1 files changed, 0 insertions, 6 deletions
@@ -112,8 +112,6 @@ static void cstr_realloc(CString *cstr, int new_size) while (size < new_size) size = size * 2; data = tcc_realloc(cstr->data_allocated, size); - if (!data) - tcc_error("memory full"); cstr->data_allocated = data; cstr->size_allocated = size; cstr->data = data; @@ -200,8 +198,6 @@ static TokenSym *tok_alloc_new(TokenSym **pts, const char *str, int len) i = tok_ident - TOK_IDENT; if ((i % TOK_ALLOC_INCR) == 0) { ptable = tcc_realloc(table_ident, (i + TOK_ALLOC_INCR) * sizeof(TokenSym *)); - if (!ptable) - tcc_error("memory full"); table_ident = ptable; } @@ -844,8 +840,6 @@ static int *tok_str_realloc(TokenString *s) len = s->allocated_len * 2; } str = tcc_realloc(s->str, len * sizeof(int)); - if (!str) - tcc_error("memory full"); s->allocated_len = len; s->str = str; return str; |
