diff options
-rw-r--r-- | src/core/page_allocator.c | 2 | ||||
-rw-r--r-- | src/core/page_allocator.h | 2 | ||||
-rw-r--r-- | src/core/std_allocator.c | 2 | ||||
-rw-r--r-- | src/core/std_allocator.h | 2 | ||||
-rw-r--r-- | src/unit/test_arena_allocator.c | 2 | ||||
-rw-r--r-- | src/unit/test_std_allocator.c | 2 |
6 files changed, 6 insertions, 6 deletions
diff --git a/src/core/page_allocator.c b/src/core/page_allocator.c index a20aa76..f00dcce 100644 --- a/src/core/page_allocator.c +++ b/src/core/page_allocator.c @@ -86,6 +86,6 @@ static SandAllocator vtable = { .user_data = NULL, }; -SandAllocator *sand_get_page_allocator() { +SandAllocator *sand_get_page_allocator(void) { return &vtable; } diff --git a/src/core/page_allocator.h b/src/core/page_allocator.h index 506cd8f..f591d89 100644 --- a/src/core/page_allocator.h +++ b/src/core/page_allocator.h @@ -6,6 +6,6 @@ #include "allocator.h" -SandAllocator *sand_get_page_allocator(); +SandAllocator *sand_get_page_allocator(void); #endif diff --git a/src/core/std_allocator.c b/src/core/std_allocator.c index ecfa806..2bfe78a 100644 --- a/src/core/std_allocator.c +++ b/src/core/std_allocator.c @@ -27,7 +27,7 @@ static void *reallocate(void *old_ptr, size_t old_size, size_t new_size, size_t return realloc(old_ptr, new_size); } -SandAllocator sand_new_std_allocator() { +SandAllocator sand_get_std_allocator(void) { return (SandAllocator) { .allocate = allocate, .deallocate = deallocate, diff --git a/src/core/std_allocator.h b/src/core/std_allocator.h index 6170272..57d419e 100644 --- a/src/core/std_allocator.h +++ b/src/core/std_allocator.h @@ -6,6 +6,6 @@ #include "allocator.h" -SandAllocator sand_new_std_allocator(); +SandAllocator sand_get_std_allocator(void); #endif diff --git a/src/unit/test_arena_allocator.c b/src/unit/test_arena_allocator.c index 5a6e3d8..eb0ad33 100644 --- a/src/unit/test_arena_allocator.c +++ b/src/unit/test_arena_allocator.c @@ -8,7 +8,7 @@ SUITE(arena_allocator) { #define RUN_WITH_ARENA(test) \ do { \ - SandAllocator parent = sand_new_std_allocator(); \ + SandAllocator parent = sand_get_std_allocator(); \ SandArena arena = sand_create_arena(&parent); \ SandAllocator a = sand_get_allocator_for_arena(&arena); \ RUN_TEST1(test, &a); \ diff --git a/src/unit/test_std_allocator.c b/src/unit/test_std_allocator.c index e115952..20464db 100644 --- a/src/unit/test_std_allocator.c +++ b/src/unit/test_std_allocator.c @@ -7,7 +7,7 @@ SUITE(std_allocator) { #define RUN_WITH_STD_ALLOCATOR(test) \ do { \ - SandAllocator a = sand_new_std_allocator(); \ + SandAllocator a = sand_get_std_allocator(); \ RUN_TEST1(test, &a); \ } while(0); |