summaryrefslogtreecommitdiff
path: root/source/kit/string_builder.h
diff options
context:
space:
mode:
Diffstat (limited to 'source/kit/string_builder.h')
-rw-r--r--source/kit/string_builder.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/kit/string_builder.h b/source/kit/string_builder.h
index c869afb..23eda65 100644
--- a/source/kit/string_builder.h
+++ b/source/kit/string_builder.h
@@ -56,7 +56,7 @@ static s32 kit_str_append(kit_str_builder_t *a, kit_str_t b) {
i64 n = a->size;
KIT_DA_RESIZE(*a, n + b.size);
if (a->size != n + b.size)
- return KIT_ERROR_BAD_ALLOC;
+ return KIT_ERROR_OUT_OF_MEMORY;
memcpy(a->values + n, b.values, b.size);
return KIT_OK;
}
@@ -71,7 +71,7 @@ static s32 kit_str_insert(kit_str_builder_t *a, i64 index,
i64 n = a->size;
KIT_DA_RESIZE(*a, n + b.size);
if (a->size != n + b.size)
- return KIT_ERROR_BAD_ALLOC;
+ return KIT_ERROR_OUT_OF_MEMORY;
if (index < n)
memmove(a->values + (index + b.size), a->values + index,
n - index);