X-Git-Url: https://git.dlugolecki.net.pl/?a=blobdiff_plain;f=gom%2Fgom.c;h=e00af9a948317ef57c9046643113eeee0a21b40b;hb=8073f669d16f11bfd50d42bb2cf6fdb79d358565;hp=3e604159bc9f5a7849e88d003204c72e20302cad;hpb=176d9749f36a9703cb834f0198db2a71aecf3416;p=gedcom-parse.git diff --git a/gom/gom.c b/gom/gom.c index 3e60415..e00af9a 100644 --- a/gom/gom.c +++ b/gom/gom.c @@ -111,10 +111,10 @@ int gom_parse_file(const char* file_name) gom_cleanup(); } else { + gedcom_set_compat_options(COMPAT_ALLOW_OUT_OF_CONTEXT); subscribe_all(); } gom_active = 1; - gedcom_set_compat_options(0); return gedcom_parse_file(file_name); } @@ -174,6 +174,26 @@ void gom_default_callback (Gedcom_elt elt UNUSED, Gedcom_ctxt parent UNUSED, level, tag, raw_value); } +void gom_mem_error(const char *filename, int line) +{ + gedcom_error(_("Could not allocate memory at %s, %d"), filename, line); +} + +void gom_xref_already_in_use(const char *xrefstr) +{ + gedcom_error(_("Cross-reference key '%s' is already in use"), xrefstr); +} + +void gom_move_error(const char* type) +{ + gedcom_warning(_("Could not move struct of type %s"), type); +} + +void gom_find_error(const char* type) +{ + gedcom_warning(_("Could not find struct of type %s in chain"), type); +} + void set_xref_type(struct xref_value* xr, const char *str) { if (!strcasecmp(str, "FAM"))