From a5ee7f31af4a004287a85d830c65c86f54889fc9 Mon Sep 17 00:00:00 2001 From: Kevin Day Date: Fri, 19 Jun 2020 15:34:06 -0500 Subject: [PATCH] Feature: add F_recurse status code The recurse status code is intended to be used for situations involving recursive operations. --- level_0/f_status/c/status.h | 1 + level_1/fl_status/c/status.c | 3 +++ level_1/fl_status/c/status.h | 2 ++ level_2/fll_status/c/status.c | 5 +++++ 4 files changed, 11 insertions(+) diff --git a/level_0/f_status/c/status.h b/level_0/f_status/c/status.h index 49b644f..286b482 100644 --- a/level_0/f_status/c/status.h +++ b/level_0/f_status/c/status.h @@ -178,6 +178,7 @@ extern "C" { F_process_too_many, F_prohibited, F_read_only, + F_recurse, F_search, F_space_not, F_stop, diff --git a/level_1/fl_status/c/status.c b/level_1/fl_status/c/status.c index 98f9bed..1fc4549 100644 --- a/level_1/fl_status/c/status.c +++ b/level_1/fl_status/c/status.c @@ -320,6 +320,9 @@ extern "C" { case F_read_only: *string = FL_status_string_read_only; break; + case F_recurse: + *string = FL_status_string_recurse; + break; case F_search: *string = FL_status_string_search; break; diff --git a/level_1/fl_status/c/status.h b/level_1/fl_status/c/status.h index 3ff9b2e..06cfde1 100644 --- a/level_1/fl_status/c/status.h +++ b/level_1/fl_status/c/status.h @@ -197,6 +197,7 @@ extern "C" { #define FL_status_string_process_too_many "F_process_too_many" #define FL_status_string_prohibited "F_prohibited" #define FL_status_string_read_only "F_read_only" + #define FL_status_string_recurse "F_recurse" #define FL_status_string_search "F_search" #define FL_status_string_space_not "F_space_not" #define FL_status_string_stop "F_stop" @@ -244,6 +245,7 @@ extern "C" { #define FL_status_string_process_too_many_length 18 #define FL_status_string_prohibited_length 12 #define FL_status_string_read_only_length 11 + #define FL_status_string_recurse_length 7 #define FL_status_string_search_length 8 #define FL_status_string_space_not_length 11 #define FL_status_string_stop_length 6 diff --git a/level_2/fll_status/c/status.c b/level_2/fll_status/c/status.c index 1d63071..877c857 100644 --- a/level_2/fll_status/c/status.c +++ b/level_2/fll_status/c/status.c @@ -536,6 +536,11 @@ extern "C" { return F_none; } + if (fl_string_compare(string, FL_status_string_recurse, length, FL_status_string_recurse_length) == F_equal_to) { + *code = F_recurse; + return F_none; + } + if (fl_string_compare(string, FL_status_string_search, length, FL_status_string_search_length) == F_equal_to) { *code = F_search; return F_none; -- 1.8.3.1