From 1784a6bd4d62d944e28130008107af226b27b208 Mon Sep 17 00:00:00 2001 From: Kevin Day Date: Tue, 7 Jan 2020 21:44:07 -0600 Subject: [PATCH] Cleanup: add period at end of sentences --- level_3/firewall/c/firewall.c | 6 +++--- level_3/firewall/c/private-firewall.c | 10 +++++----- level_3/firewall/c/private-firewall.h | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/level_3/firewall/c/firewall.c b/level_3/firewall/c/firewall.c index f740b2b..3fada99 100644 --- a/level_3/firewall/c/firewall.c +++ b/level_3/firewall/c/firewall.c @@ -181,7 +181,7 @@ extern "C" { f_macro_string_dynamics_resize(status, parameters, 7); if (f_status_is_error(status)) { - fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory."); firewall_delete_local_data(&local); firewall_delete_data(data); return status; @@ -271,7 +271,7 @@ extern "C" { status = f_status_set_fine(status); if (status == f_error_allocation || status == f_error_reallocation) { - fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory."); } else { fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "ERROR: Failed to perform requested %s operation:", firewall_tool_iptables); @@ -321,7 +321,7 @@ extern "C" { status = f_status_set_fine(status); if (status == f_error_allocation || status == f_error_reallocation) { - fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "CRITICAL ERROR: Unable to allocate memory."); } else if (status == f_no_data) { fl_color_print_line(f_standard_error, data->context.error, data->context.reset, "ERROR: could not find any network devices"); diff --git a/level_3/firewall/c/private-firewall.c b/level_3/firewall/c/private-firewall.c index 54f0fce..7aad2b6 100644 --- a/level_3/firewall/c/private-firewall.c +++ b/level_3/firewall/c/private-firewall.c @@ -600,7 +600,7 @@ f_return_status firewall_perform_commands(const firewall_local_data local, const fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "ERROR: File descriptor error while trying to open the file '%.*s'", file_path.used, file_path.string); } else if (status == f_error_allocation || status == f_error_reallocation) { - fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); } else { fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "INTERNAL ERROR: An unhandled error (%u) has occurred while calling f_file_open()", status); @@ -642,7 +642,7 @@ f_return_status firewall_perform_commands(const firewall_local_data local, const fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "ERROR: A read error occurred while accessing the file '%.*s'", file_path.used, file_path.string); } else if (status == f_error_allocation || status == f_error_reallocation) { - fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); } else { fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "INTERNAL ERROR: An unhandled error (%u) has occurred while calling fl_file_read()", status); @@ -669,7 +669,7 @@ f_return_status firewall_perform_commands(const firewall_local_data local, const // empty files are to be silently ignored } else if (status == f_error_allocation || status == f_error_reallocation) { - fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); } else { fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "INTERNAL ERROR: An unhandled error (%u) has occurred while calling fll_fss_basic_read() for the file '%.*s'", status, file_path.used, file_path.string); @@ -705,7 +705,7 @@ f_return_status firewall_perform_commands(const firewall_local_data local, const } if (f_status_is_error(status)) { - fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); f_macro_string_dynamic_delete_simple(ip_list_action); } @@ -725,7 +725,7 @@ f_return_status firewall_perform_commands(const firewall_local_data local, const f_macro_string_dynamic_new(status, ip_argument, ip_length); if (f_status_is_error(status)) { - fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); + fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); break; } diff --git a/level_3/firewall/c/private-firewall.h b/level_3/firewall/c/private-firewall.h index bc4b443..2c3b1b1 100644 --- a/level_3/firewall/c/private-firewall.h +++ b/level_3/firewall/c/private-firewall.h @@ -88,7 +88,7 @@ typedef struct { (structure.array[index].stop - structure.array[index].start) + 1 // TODO: temporarily added, convert this to a function below. -// TODO: also report: fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory"); +// TODO: also report: fl_color_print_line(f_standard_error, data.context.error, data.context.reset, "CRITICAL ERROR: Unable to allocate memory."); #define firewall_macro_append_argument_to_arguments(status, arguments, argument) \ if (arguments.used >= arguments.size) { \ f_macro_string_dynamics_resize(status, arguments, arguments.used + firewall_default_allocation_step); \ -- 1.8.3.1