X-Git-Url: https://git.dlugolecki.net.pl/?a=blobdiff_plain;ds=sidebyside;f=t%2Fsrc%2Fstandalone.c;fp=t%2Fsrc%2Fstandalone.c;h=44483e7768bbc73a57755ea4ff82c50dea67c0aa;hb=e27dbec88a292363b9b5992c1b6b53d584111ad8;hp=22eb56f33998cb2b4740b51b2d9365f61043f5e7;hpb=c034f8250dc36051ab609bfcb1a149326c5ffe24;p=gedcom-parse.git diff --git a/t/src/standalone.c b/t/src/standalone.c index 22eb56f..44483e7 100644 --- a/t/src/standalone.c +++ b/t/src/standalone.c @@ -32,6 +32,7 @@ #include "utf8-locale.h" #define BOGUS_FILE_NAME "Makefile.am" +int total_conv_fails = 0; void show_help () { @@ -185,6 +186,7 @@ void default_cb(Gedcom_elt elt, Gedcom_ctxt ctxt, int level, char *tag, converted = convert_utf8_to_locale(raw_value, &conv_fails); output(0, "== %d %s (%d) %s (ctxt is %d, conversion failures: %d)\n", level, tag, tag_value, converted, (int)ctxt, conv_fails); + total_conv_fails += conv_fails; } void subscribe_callbacks() @@ -293,6 +295,7 @@ int main(int argc, char* argv[]) while (run_times-- > 0) { output(0, "\n=== Parsing file %s\n", file_name); result |= gedcom_parse_file(file_name); + output(0, "\n=== Total conversion failures: %d\n", total_conv_fails); } if (result == 0) { output(1, "Parse succeeded\n");