From: Kevin Day Date: Mon, 23 Nov 2020 03:53:57 +0000 (-0600) Subject: Update: handle F_incomplete_utf status. X-Git-Tag: 0.5.2~59 X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=e1ab16459d6b624722e412868ae30d9ed37e97d3;p=fll Update: handle F_incomplete_utf status. --- diff --git a/level_2/fll_error/c/private-error.c b/level_2/fll_error/c/private-error.c index 46ab32f..744283d 100644 --- a/level_2/fll_error/c/private-error.c +++ b/level_2/fll_error/c/private-error.c @@ -86,6 +86,19 @@ extern "C" { return F_false; } + if (status == F_incomplete_utf) { + if (error.verbosity != f_console_verbosity_quiet) { + fprintf(error.to.stream, "%c", f_string_eol[0]); + fprintf(error.to.stream, "%s%sInvalid (incomplete) UTF-8 character while calling ", error.context.before->string, error.prefix ? error.prefix : ""); + + private_fll_error_print_function(error, function); + + fprintf(error.to.stream, ".%s%c", error.context.after->string, f_string_eol[0]); + } + + return F_false; + } + if (fallback && error.verbosity != f_console_verbosity_quiet) { if (error.verbosity != f_console_verbosity_quiet) { fprintf(error.to.stream, "%c", f_string_eol[0]);