X-Git-Url: https://git.dlugolecki.net.pl/?a=blobdiff_plain;f=gedcom%2Finterface.c;h=aae15e485dcf73182cb11763b5d2f280fbd80061;hb=6103dd898c4de86c68891cc0222543988a2caab7;hp=8b42b213f013fc533ba32e10507ebad3cbc5245f;hpb=31fb8432ef01f9d5a08cc801a785a07b4e9d12bd;p=gedcom-parse.git diff --git a/gedcom/interface.c b/gedcom/interface.c index 8b42b21..aae15e4 100644 --- a/gedcom/interface.c +++ b/gedcom/interface.c @@ -126,3 +126,14 @@ void gedcom_cast_error(const char* file, int line, (_("Wrong cast of value in file %s, at line %d: %s instead of %s"), file, line, _(val_type_str[tried_bit]), _(val_type_str[real_bit])); } + +/** This function allows to customize what happens on an error. It doesn't + influence the generation of error or warning messages, only the behaviour + of the parser and its return code. See \ref Gedcom_err_mech for the + possible mechanisms. + */ + +void gedcom_set_error_handling(Gedcom_err_mech mechanism) +{ + error_mechanism = mechanism; +}