]> Kevux Git Server - kevux-tools/commitdiff
Cleanup: Switch from 'callback' to 'call'.
authorKevin Day <Kevin@kevux.org>
Sat, 6 Dec 2025 04:53:11 +0000 (22:53 -0600)
committerKevin Day <Kevin@kevux.org>
Sat, 6 Dec 2025 04:53:11 +0000 (22:53 -0600)
sources/c/program/kevux/tools/remove/main/operate.h
sources/c/program/kevux/tools/remove/main/remove.h
sources/c/program/kevux/tools/tacocat/main/common.c
sources/c/program/kevux/tools/tacocat/main/common.h
sources/c/program/kevux/tools/tacocat/main/common/type.h
sources/c/program/kevux/tools/tacocat/main/tacocat.h
sources/c/program/kevux/tools/tacocat/tacocat/main.c

index fb7db05241d0766a011ec43a89c42dbc397741f8..8ce60ddda0e00391dbef29e667cbd4d54945f706 100644 (file)
@@ -25,7 +25,7 @@ extern "C" {
  *   The path to the file to operate on.
  *
  *   This should always be TRUE when calling from the top level.
- *   This should always be FALSE if calling from within a fl_directory_do() callback.
+ *   This should always be FALSE if calling from within a fl_directory_do() call back.
  *   This is because fl_directory_do() handles directory traversal and processing.
  * @param recurse
  *   One of the kt_remove_flag_recurse_*_d flags.
@@ -79,7 +79,7 @@ extern "C" {
  *   The path to the file to operate on.
  *
  *   This should always be TRUE when calling from the top level.
- *   This should always be FALSE if calling from within a fl_directory_do() callback.
+ *   This should always be FALSE if calling from within a fl_directory_do() call back.
  *   This is because fl_directory_do() handles directory traversal and processing.
  * @param flag_operate
  *   The operate file specific flags from kt_remove_flag_operate_*_e.
index c0ed02f3962866681098f433e9cd9017185c179c..e52bb8593b738b9930c70d5becfa8fae65fb2f4b 100644 (file)
@@ -94,7 +94,7 @@ extern "C" {
  *
  *     F_interrupt (with error bit) on (exit) signal received.
  *
- *     Errors (with error bit) from: main.callback.process_normal().
+ *     Errors (with error bit) from: main.call.process_normal().
  */
 #ifndef _di_kt_remove_main_
   extern void kt_remove_main(kt_remove_main_t * const main);
index b9636cef9cbfcd25c66ea95c79fb5c65f4bfa8c5..3f762f4489ea809c934710c084ffbb6dca9117a4 100644 (file)
@@ -221,8 +221,8 @@ extern "C" {
     }
 
     // Only process these when needed to avoid unnecessary operations.
-    if (main->callback.setting_load_send_receive && !(main->setting.flag & (kt_tacocat_main_flag_copyright_d | kt_tacocat_main_flag_version_d |kt_tacocat_main_flag_help_d))) {
-      main->callback.setting_load_send_receive(arguments, main);
+    if (main->call.setting_load_send_receive && !(main->setting.flag & (kt_tacocat_main_flag_copyright_d | kt_tacocat_main_flag_version_d |kt_tacocat_main_flag_help_d))) {
+      main->call.setting_load_send_receive(arguments, main);
     }
 
     if (F_status_is_error_not(main->setting.state.status)) {
index 830c1317a9f014395706e81490ca1fdcee4bdaea..6b1732cf27cb8a871de91f4ab74a3a18afa8e551 100644 (file)
@@ -80,7 +80,7 @@ extern "C" {
  *     Errors (with error bit) from: f_network_from_ip_name().
  *     Errors (with error bit) from: f_string_dynamic_append_nulless().
  *
- *     Errors (with error bit) from: main.callback.setting_load_send_receive().
+ *     Errors (with error bit) from: main.call.setting_load_send_receive().
  *
  * @see f_file_exists()
  * @see f_file_open()
index 0de9e43bbf9fd75b01f897c332294ef4d68d4735..c65bc3800c7733c567de843c4bd5bfece4d0eec7 100644 (file)
@@ -404,15 +404,15 @@ extern "C" {
  *
  * setting_load_send_receive: Process loading the settings regarding send and receive, handling DNS resolution and file opening as needed.
  */
-#ifndef _di_kt_tacocat_callback_t_
+#ifndef _di_kt_tacocat_call_t_
   typedef struct {
     void (*setting_load_send_receive)(const f_console_arguments_t arguments, kt_tacocat_main_t * const main);
-  } kt_tacocat_callback_t;
+  } kt_tacocat_call_t;
 
-  #define kt_tacocat_callback_t_initialize { \
+  #define kt_tacocat_call_t_initialize { \
     .setting_load_send_receive = 0, \
   }
-#endif // _di_kt_tacocat_callback_t_
+#endif // _di_kt_tacocat_call_t_
 
 /**
  * The main thread settings.
@@ -432,26 +432,27 @@ extern "C" {
 /**
  * The main program data as a single structure.
  *
+ * cache:    The program cache.
+ * call:     The program callbacks.
  * program:  The main program data.
  * setting:  The settings data.
- * callback: The program callbacks.
  * thread:   The program thread data.
  */
 #ifndef _di_kt_tacocat_main_t_
   struct kt_tacocat_main_t_ {
+    kt_tacocat_cache_t cache;
+    kt_tacocat_call_t call;
     fll_program_data_t program;
     kt_tacocat_setting_t setting;
-    kt_tacocat_callback_t callback;
     kt_tacocat_thread_t thread;
-    kt_tacocat_cache_t cache;
   };
 
   #define kt_tacocat_main_t_initialize { \
+    .cache    = kt_tacocat_cache_t_initialize, \
+    .call = kt_tacocat_call_t_initialize, \
     .program  = fll_program_data_t_initialize, \
     .setting  = kt_tacocat_setting_t_initialize, \
-    .callback = kt_tacocat_callback_t_initialize, \
     .thread   = kt_tacocat_thread_t_initialize, \
-    .cache    = kt_tacocat_cache_t_initialize, \
   }
 #endif // _di_kt_tacocat_main_t_
 
@@ -496,7 +497,7 @@ extern "C" {
 #endif // _di_kt_tacocat_setting_delete_
 
 /**
- * A callback intended to be passed to f_memory_arrays_resize() for an kt_tacocat_socket_sets_t structure.
+ * A call back intended to be passed to f_memory_arrays_resize() for an kt_tacocat_socket_sets_t structure.
  *
  * This is only called when shrinking the array and generally should perform deallocations.
  *
index 030d023a19122ce9689979791370e1c35510aa08..b3343986502382cc905ff9702955f14cd984aeb0 100644 (file)
@@ -116,7 +116,7 @@ extern "C" {
  *
  *     F_interrupt (with error bit) on (exit) signal received.
  *
- *     Errors (with error bit) from: main.callback.process_normal().
+ *     Errors (with error bit) from: main.call.process_normal().
  */
 #ifndef _di_kt_tacocat_main_
   extern void kt_tacocat_main(kt_tacocat_main_t * const main);
index 441690de7112c479e3730863b6be7ae09e433ea7..43aee807218d1da8965069e91b803214a80ec3b4 100644 (file)
@@ -28,7 +28,7 @@ int main(const int argc, const f_string_t *argv, const f_string_t *envp) {
   data.program.parameters.used = kt_tacocat_parameter_total_d;
   data.program.environment = envp;
 
-  data.callback.setting_load_send_receive = kt_tacocat_setting_load_send_receive;
+  data.call.setting_load_send_receive = kt_tacocat_setting_load_send_receive;
 
   if (f_pipe_input_exists()) {
     data.program.pipe = fll_program_data_pipe_input_e;