From b29f4153e83623f24bebe99976e1368ef31bb008 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Thu, 21 May 2026 17:12:20 +0200 Subject: Add support for custom hash functions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- librecrypt_free_context.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'librecrypt_free_context.c') diff --git a/librecrypt_free_context.c b/librecrypt_free_context.c index 481282f..b2a62c9 100644 --- a/librecrypt_free_context.c +++ b/librecrypt_free_context.c @@ -6,6 +6,8 @@ void librecrypt_free_context(LIBRECRYPT_CONTEXT *ctx) { + if (!ctx) + return; librecrypt_wipe(ctx, sizeof(*ctx)); free(ctx); } @@ -14,15 +16,11 @@ librecrypt_free_context(LIBRECRYPT_CONTEXT *ctx) #else -int +CONST int main(void) { - SET_UP_ALARM(); - INIT_RESOURCE_TEST(); - - /* TODO test */ - - STOP_RESOURCE_TEST(); + /* Tested in other files */ + librecrypt_free_context(NULL); return 0; } -- cgit v1.3.1