diff options
author | Aryadev Chavali <aryadev@aryadevchavali.com> | 2024-12-19 08:44:10 +0000 |
---|---|---|
committer | Aryadev Chavali <aryadev@aryadevchavali.com> | 2024-12-19 08:44:10 +0000 |
commit | 2a4d7addaea5883213841b3ab6372346e70ccef3 (patch) | |
tree | e9af08a15b94271a16eeb922aa124be55e21606a /lib.h | |
parent | 22d1f712aebd6ec4473a98d87d4d64f2f525943f (diff) | |
download | obf-2a4d7addaea5883213841b3ab6372346e70ccef3.tar.gz obf-2a4d7addaea5883213841b3ab6372346e70ccef3.tar.bz2 obf-2a4d7addaea5883213841b3ab6372346e70ccef3.zip |
Delete buffer stretchy functions
A buffer should be a strictly sized array representing a file in
memory. No dynamic size functions.
Diffstat (limited to 'lib.h')
-rw-r--r-- | lib.h | 6 |
1 files changed, 1 insertions, 5 deletions
@@ -29,13 +29,9 @@ void print_error(const char *handle, size_t row, size_t column, typedef struct Buffer { const char *name; - u64 size, capacity; + u64 size; u8 data[]; } buffer_t; buffer_t *buffer_init_str(const char *name, const char *str, size_t str_size); -bool buffer_ensure(buffer_t **buffer, u64 expected); -bool buffer_ensure_relative(buffer_t **buffer, u64 expected); -bool buffer_append(buffer_t **buffer, u8 datum); -bool buffer_append_bytes(buffer_t **buffer, u8 *data, u64 size); #endif |