RE: [xml] when to call initGenericErrorDefaultFunc()
- From: "Labib Iskander, Marcus" <ml cm4all com>
- To: "'xml gnome org'" <xml gnome org>
- Subject: RE: [xml] when to call initGenericErrorDefaultFunc()
- Date: Tue, 22 Oct 2002 16:12:41 +0200
hi,
since I didn't use it till now, I can't tell how to use the error handling
functionality of libxml, but I would like to remark, that
initGenericErrorDefaultFunc(gitk_libxml_error_func);
is implicitly converted to:
initGenericErrorDefaultFunc(&gitk_libxml_error_func);
these two calls are semantically identical. The problem is rather that
initGenericErrorDefaultFunc takes a pointer to a function pointer as an
argument and directs this pointer to the default error handling function:
xmlerror.h:
typedef void (*xmlGenericErrorFunc) (void *ctx,
const char *msg,
...);
error.c:
void
initGenericErrorDefaultFunc(xmlGenericErrorFunc * handler)
{
if (handler == NULL)
xmlGenericError = xmlGenericErrorDefaultFunc;
else
(*handler) = xmlGenericErrorDefaultFunc;
}
Cheers,
Marcus
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]