diff options
author | Daniel Veillard <veillard@src.gnome.org> | 2001-10-13 09:15:48 +0000 |
---|---|---|
committer | Daniel Veillard <veillard@src.gnome.org> | 2001-10-13 09:15:48 +0000 |
commit | d0463560300f1d8b3e41d70c3728ed84fdc8dd30 (patch) | |
tree | 559d845bad18c3c44cf7d08cc738efc9ea573b78 /error.c | |
parent | b847864fc2f7151c81e57d02ca3b523dc5d8cf72 (diff) | |
download | libxml2-d0463560300f1d8b3e41d70c3728ed84fdc8dd30.tar.gz |
Applied the last patches from Gary, cleanup, activated threading all user
* include/libxml/SAX.h include/libxml/globals.h include/libxml/parser.h
include/libxml/parserInternals.h include/libxml/tree.h
include/libxml/xmlerror.h HTMLparser.c SAX.c error.c globals.c
nanoftp.c nanohttp.c parser.c parserInternals.c testDocbook.c
testHTML.c testSAX.c tree.c uri.c xlink.c xmlmemory.c:
Applied the last patches from Gary, cleanup, activated threading
all user accessible global variables are now handled in globals.[ch]
Still a bit rought but make tests passes with either
--with-threads defined at configure time or not.
* Makefile.am example/Makefile.am: added globals.[ch] and threads
linking options
Daniel
Diffstat (limited to 'error.c')
-rw-r--r-- | error.c | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -69,9 +69,14 @@ xmlGenericErrorDefaultFunc(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...) { va_end(args); } -xmlGenericErrorFunc xmlGenericError = xmlGenericErrorDefaultFunc; -void *xmlGenericErrorContext = NULL; - +void +initGenericErrorDefaultFunc(xmlGenericErrorFunc *handler) +{ + if (handler == NULL) + xmlGenericError = xmlGenericErrorDefaultFunc; + else + (*handler) = xmlGenericErrorDefaultFunc; +} /** * xmlSetGenericErrorFunc: |