From: Kevin Day Date: Wed, 24 Jun 2020 05:15:28 +0000 (-0500) Subject: Update: add f_macro_file_clear() and f_macro_file_reset() X-Git-Tag: 0.5.0~136 X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=dca7576a295652004d985cd1197a3e2bfc121038;p=fll Update: add f_macro_file_clear() and f_macro_file_reset() --- diff --git a/level_0/f_file/c/file.h b/level_0/f_file/c/file.h index 07c9d45..ecb8cb6 100644 --- a/level_0/f_file/c/file.h +++ b/level_0/f_file/c/file.h @@ -107,6 +107,18 @@ extern "C" { } f_file; #define f_file_initialize { 0, f_file_flag_read_only, f_file_default_read_size, f_file_default_write_size } + + #define f_macro_file_clear(file) \ + file.id = 0; \ + file.flag = 0; \ + file.size_read = 0; \ + file.size_write = 0; + + #define f_macro_file_reset(file) \ + file.id = 0; \ + file.flag = f_file_flag_read_only; \ + file.size_read = f_file_default_read_size; \ + file.size_write = f_file_default_write_size; #endif // _di_f_file_ /**