aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib.c2
-rw-r--r--lib.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib.c b/lib.c
index 0c32c3b..3be6e0a 100644
--- a/lib.c
+++ b/lib.c
@@ -67,7 +67,7 @@ char *fread_all(FILE *fp)
return buffer.data;
}
-void vec_append(vec_t *vec, void *ptr, u64 size)
+void vec_append(vec_t *vec, const void *const ptr, u64 size)
{
vec_ensure_free(vec, size);
memcpy(vec->data + vec->size, ptr, size);
diff --git a/lib.h b/lib.h
index 4fb390e..c58d425 100644
--- a/lib.h
+++ b/lib.h
@@ -41,7 +41,7 @@ typedef struct
u8 *data;
} vec_t;
-void vec_append(vec_t *vec, void *ptr, u64 size);
+void vec_append(vec_t *vec, const void *const ptr, u64 size);
void vec_ensure(vec_t *vec, u64 abs_size);
void vec_ensure_free(vec_t *vec, u64 rel_size);
void vec_free(vec_t *vec);