From e3dd54fda9949dd9a9eb205e8f708909541c005f Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Tue, 28 Jan 2025 13:20:09 -0500 Subject: [PATCH] spelling: contiguous Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- src/libutil/circular_buffer.c | 4 ++-- tests/libutil/test_circular_buffer.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libutil/circular_buffer.c b/src/libutil/circular_buffer.c index ed6cede2..fb511a37 100644 --- a/src/libutil/circular_buffer.c +++ b/src/libutil/circular_buffer.c @@ -143,8 +143,8 @@ bool circular_buffer_read_or_copy(const CircularBuffer* buffer, uint8_t **data_o if (buffer->data_length < length) { return false; } - const uint16_t continguous_length = (buffer->buffer_size - buffer->read_index); - const bool should_malloc_and_copy = (length > continguous_length); + const uint16_t contiguous_length = (buffer->buffer_size - buffer->read_index); + const bool should_malloc_and_copy = (length > contiguous_length); *caller_should_free = should_malloc_and_copy; if (should_malloc_and_copy) { *data_out = (uint8_t *) malloc_imp(length); diff --git a/tests/libutil/test_circular_buffer.c b/tests/libutil/test_circular_buffer.c index 5ac5ab2a..347f3ee4 100644 --- a/tests/libutil/test_circular_buffer.c +++ b/tests/libutil/test_circular_buffer.c @@ -213,7 +213,7 @@ void test_circular_buffer__read_or_copy_returns_false_when_length_is_too_long(vo malloc, &caller_should_free)); } -void test_circular_buffer__read_or_copy_doesnt_copy_when_already_continguously_stored(void) { +void test_circular_buffer__read_or_copy_doesnt_copy_when_already_contiguously_stored(void) { CircularBuffer buffer; uint8_t storage[8]; circular_buffer_init(&buffer, storage, sizeof(storage)); @@ -230,7 +230,7 @@ static void *prv_oom_malloc(size_t length) { return NULL; } -void test_circular_buffer__read_or_copy_does_copy_when_not_continguously_stored(void) { +void test_circular_buffer__read_or_copy_does_copy_when_not_contiguously_stored(void) { CircularBuffer buffer; uint8_t storage[8]; circular_buffer_init(&buffer, storage, sizeof(storage));