diff options
Diffstat (limited to 'dseg.c')
| -rw-r--r-- | dseg.c | 6 |
1 files changed, 1 insertions, 5 deletions
@@ -50,11 +50,7 @@ static void ent_assign_key(struct dseg_entry* ent) { switch (ent->type) { case ENT_STRING: integral_t strnum = string_counter++; - int req_sz = snprintf(NULL, 0, STRING_PATTERN, strnum); - if (req_sz < 0) CCC_PANIC; - req_sz += 1; // null terminator - ent->symbol = ccc_alloc(req_sz); - snprintf(ent->symbol, req_sz, STRING_PATTERN, strnum); + ent->symbol = ccc_sprintf(STRING_PATTERN, strnum); break; } } |
