X-Git-Url: https://git.dlugolecki.net.pl/?a=blobdiff_plain;f=gedcom%2Fmessage.c;h=bac44078646741153d1922cf70a3c1055b188b26;hb=refs%2Fheads%2Flibiconv-gedcom-1.14;hp=6943f6078c9b2b2fb6836eac1e25deaffc9cf159;hpb=d1ef17aad36016326df1d243dd243ecbdd8a819a;p=gedcom-parse.git diff --git a/gedcom/message.c b/gedcom/message.c index 6943f60..bac4407 100644 --- a/gedcom/message.c +++ b/gedcom/message.c @@ -27,9 +27,15 @@ void cleanup_mess_buffer(); -struct safe_buffer mess_buffer = { NULL, 0, cleanup_mess_buffer }; +struct safe_buffer mess_buffer = { NULL, 0, NULL, 0, cleanup_mess_buffer }; Gedcom_msg_handler msg_handler = NULL; +/** This function registers a callback that is called if there are errors, + warnings or just messages coming from the parser. + + \param func The callback to be called on errors, warnings or messages; see + \ref Gedcom_msg_handler for the signature of the callback. +*/ void gedcom_set_message_handler(Gedcom_msg_handler func) { msg_handler = func;