From 1444c72db8505340c0988ea286a29bc261297933 Mon Sep 17 00:00:00 2001 From: "@syxhe" Date: Mon, 9 Jun 2025 17:43:50 -0500 Subject: We do a little documentation --- src/shared.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/shared.c') diff --git a/src/shared.c b/src/shared.c index c02414b..40732f0 100644 --- a/src/shared.c +++ b/src/shared.c @@ -1,3 +1,14 @@ +/** + * @file shared.c + * @author syxhe (https://t.me/syxhe) + * @brief *Implementing `shared.h`* + * @version 0.1 + * @date 2025-06-09 + * + * @copyright Copyright (c) 2025 + * + */ + #include "shared.h" #include @@ -201,7 +212,6 @@ int cleanup_init(cleanup *loc, fcallback callbacks[], void *arguments[], int siz return 0; } -// registers if flag is NOT set int cleanup_register(cleanup *loc, fcallback cb, void *arg) { if(!loc || !cb) ERRRET(EINVAL, -1); if(loc->used >= loc->size || loc->used < 0) ERRRET(ENOMEM, -1); @@ -213,6 +223,7 @@ int cleanup_register(cleanup *loc, fcallback cb, void *arg) { return 0; } +// registers if flag is NOT set int cleanup_cndregister(cleanup *loc, fcallback cb, void *arg, unsigned char flag) { if(flag) return 0; return cleanup_register(loc, cb, arg); -- cgit v1.2.3