diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2021-01-20 16:47:05 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2021-01-20 16:47:05 +0000 |
| commit | c5031be4899ea516635ef7c65a6f82b3b45860b9 (patch) | |
| tree | 10948eb4aface28e80d6a075fecf11fad3075618 /extract.c | |
| parent | Merge branch 'decset-1047-and-1048' (diff) | |
| parent | debug: rename assert() to xassert(), to avoid clashing with <assert.h> (diff) | |
Merge branch 'stacktrace'
Diffstat (limited to 'extract.c')
| -rw-r--r-- | extract.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -46,7 +46,7 @@ ensure_size(struct extraction_context *ctx, size_t additional_chars) ctx->size = new_size; } - assert(ctx->size >= ctx->idx + additional_chars); + xassert(ctx->size >= ctx->idx + additional_chars); return true; } @@ -71,8 +71,8 @@ extract_finish(struct extraction_context *ctx, char **text, size_t *len) goto out; ctx->buf[ctx->idx++] = L'\0'; } else { - assert(ctx->idx > 0); - assert(ctx->idx <= ctx->size); + xassert(ctx->idx > 0); + xassert(ctx->idx <= ctx->size); if (ctx->buf[ctx->idx - 1] == L'\n') ctx->buf[ctx->idx - 1] = L'\0'; else { |
