]> Kevux Git Server - fll/commitdiff
Update: Use status_signal instead of status_thread.
authorKevin Day <kevin@kevux.org>
Thu, 13 Jul 2023 03:24:07 +0000 (22:24 -0500)
committerKevin Day <kevin@kevux.org>
Thu, 13 Jul 2023 03:24:07 +0000 (22:24 -0500)
The status_thread is being used specifically for the signal thread.
Change the standard practice to have this renamed to status_signal.

This then helps make other status names make more sense.
Rather than have status_thread, status_thread_a, and status_thread_b, instead have status_signal, status_a, and status_b.

16 files changed:
level_3/fake/c/main/common/type.h
level_3/fake/c/main/signal.c
level_3/fss_identify/c/main/common/type.h
level_3/fss_identify/c/main/signal.c
level_3/fss_read/c/main/common/type.h
level_3/fss_read/c/main/signal.c
level_3/fss_write/c/main/common/type.h
level_3/fss_write/c/main/signal.c
level_3/iki_read/c/main/common/type.h
level_3/iki_read/c/main/signal.c
level_3/iki_write/c/main/common/type.h
level_3/iki_write/c/main/signal.c
level_3/status_code/c/main/common/type.h
level_3/status_code/c/main/signal.c
level_3/utf8/c/main/common/type.h
level_3/utf8/c/main/signal.c

index 5b046b7f102024bb3537c72526ffe90971565a9a..dd2531ff2e92d1cf4bf54ac9b7af4b3205b73ef4 100644 (file)
@@ -60,7 +60,7 @@ extern "C" {
  *
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * build:    The build directory.
@@ -80,7 +80,7 @@ extern "C" {
   typedef struct {
     uint32_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_string_dynamic_t build;
index 5b15ab63d22a486ce6a2c3ccca1686a06512c56b..1d774c311e9c1c515b2302ef40bd2a64254c2335 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= fake_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 814cfe9142a636789383d9fc5c979e272b45ca63..d936bbde433cfe0793992ee4033906428d1e751c 100644 (file)
@@ -30,7 +30,7 @@ extern "C" {
  *
  * range: A range used for processing as needed.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state information.
  *
  * buffer:A buffer used for processing files.
@@ -48,7 +48,7 @@ extern "C" {
 
     f_string_range_t range;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_file_t file;
index 4272b3a732492c6969a1db83f32cccf93e9e236a..34774eeefa2ebf5ae3b2c7892e8c2a9a51e2b110 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= fss_identify_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 7464660dc868f0bfd43281cfeba21fda1aa9c913..d0d97b9d2ae2ad77ce543f3fe0c0d44117cefa7d 100644 (file)
@@ -192,7 +192,7 @@ extern "C" {
  * flag:         Flags passed to the main function.
  * delimit_mode: The delimit mode.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * delimit_depth: The delimit depth.
@@ -221,7 +221,7 @@ extern "C" {
     uint32_t flag;
     uint8_t delimit_mode;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_number_unsigned_t delimit_depth;
index 28866d385ad538d83b147e4c4bb193389052e705..c4fa7218c3522194f906d7ac74ddc65d3d1d0376 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= fss_read_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index ecdfb3e451e716fb8f82b5406c29ae065a10444f..e2142a9d494260aeb320c44c216c9bef069f8f18 100644 (file)
@@ -57,7 +57,7 @@ extern "C" {
  *
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * range: A range used in conjunction with some buffer during processing.
@@ -82,7 +82,7 @@ extern "C" {
   typedef struct {
     uint16_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_string_range_t range;
index 7b559fe62a2df288a70a7bbf76d91e87fc338bab..f04c28f378fb324001c66ebab3ec15ea451dbcf2 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= fss_write_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 8ffdee4073037769b73a1f05e16acbd5c3a26410..97322bf8ad8e5af49e5e50f049d3098ebc86ec8c 100644 (file)
@@ -24,7 +24,7 @@ extern "C" {
  *
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * at:   The position representing the "at" index.
@@ -48,7 +48,7 @@ extern "C" {
   typedef struct {
     uint16_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_number_unsigned_t at;
index 1466235204e5025cbbacc25e9aae388669ca5749..f5b2bb38640a44132df308bdb74fda793088c7ce 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= iki_read_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 09c62ad0d865e5c065ebb82fa852774d7bbae72d..45c12b827be984355bb2c94398f8369255e2c77d 100644 (file)
@@ -24,7 +24,7 @@ extern "C" {
  *
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * quote: This holds the quote used during processing.
@@ -41,7 +41,7 @@ extern "C" {
   typedef struct {
     uint16_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_string_static_t quote;
index 36db0a87595106c33eede121bbcdd6ebc79ede40..1c91ca4aacd84fa17746c420084b65ab7d6f8d5e 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= iki_write_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 5c7c8f99c71dae7ceb3613cd59e07199cb8e08d7..93be6802867ac9c6d9858ec7a668b571e295213f 100644 (file)
@@ -24,7 +24,7 @@ extern "C" {
  *
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * status_string_from:        A pointer to the status string function (usually either fl_status_string_from() or fll_fss_status_string_from()).
@@ -35,7 +35,7 @@ extern "C" {
   typedef struct {
     uint16_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     const f_string_static_t *program_name;
index 4d14be9c5ad4401af0ca4bf299921bf41e1aa365..3a15462710d62e64ef10c6952df4c42ebc419914 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= status_code_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }
index 6263cd73aed3d981e717c8e9e33cc6ddd57df9a5..e4c08e48fbdc6b6933da285c93e03e8ebe664c3f 100644 (file)
@@ -25,7 +25,7 @@ extern "C" {
  * mode: The input/output mode (see utf8_modes_e).
  * flag: Flags passed to the main function.
  *
- * status_thread: A status used eclusively by the threaded signal handler.
+ * status_signal: A status used eclusively by the threaded signal handler.
  * state:         The state data used when processing the FSS data.
  *
  * valid:     Designate the output context set for valid characters.
@@ -46,7 +46,7 @@ extern "C" {
     uint8_t mode;
     uint16_t flag;
 
-    f_status_t status_thread;
+    f_status_t status_signal;
     f_state_t state;
 
     f_color_set_t valid;
index 9ab459a186349e66befa57c63e24aef6f4fa795b..d71cab128a163d46e0628a4b22f233999f9e82e0 100644 (file)
@@ -65,9 +65,9 @@ extern "C" {
     f_signal_set_add(F_signal_termination, &main->program.signal.set);
 
     if (main->program.signal.id == -1) {
-      main->setting.status_thread = f_signal_open(&main->program.signal);
+      main->setting.status_signal = f_signal_open(&main->program.signal);
 
-      if (F_status_is_error(main->setting.status_thread)) {
+      if (F_status_is_error(main->setting.status_signal)) {
         main->program.signal_received = F_signal_abort;
 
         return;
@@ -77,9 +77,9 @@ extern "C" {
     do {
       memset(&information, 0, sizeof(siginfo_t));
 
-      main->setting.status_thread = f_signal_wait(&main->program.signal.set, &information);
+      main->setting.status_signal = f_signal_wait(&main->program.signal.set, &information);
 
-      if (F_status_is_error(main->setting.status_thread) && F_status_set_fine(main->setting.status_thread) != F_interrupt) {
+      if (F_status_is_error(main->setting.status_signal) && F_status_set_fine(main->setting.status_signal) != F_interrupt) {
         if (++failsafe >= utf8_signal_check_failsafe_d) break;
       }
 
@@ -96,13 +96,13 @@ extern "C" {
       }
 
       failsafe = 0;
-      main->setting.status_thread = F_none;
+      main->setting.status_signal = F_none;
 
     } while (!main->program.signal_received);
 
     f_signal_close(&main->program.signal);
 
-    if (F_status_is_error(main->setting.status_thread)) {
+    if (F_status_is_error(main->setting.status_signal)) {
       main->program.signal_received = F_signal_abort;
     }
   }