dict.c


Log

Author Commit Date CI Message
Nick Wellnhofer e78e05c9 2025-05-02T17:32:51 doc: Fix autolinks to functions Unfortunately, autolinks in .c files aren't converted by Doxygen for some reason.
Nick Wellnhofer e525564f 2025-05-01T19:20:06 doc: Remove empty lines at start of block These lines were left over after automatic conversion.
Nick Wellnhofer e549622b 2025-04-28T15:11:24 doc: Convert documentation to Doxygen Automated conversion based on a few regexes.
Nick Wellnhofer 69879da8 2025-04-28T14:04:30 doc: Remove email addresses from documentation Also remove authorship information from generated files, hash.c and globals.c which were rewritten.
Nick Wellnhofer 61890e39 2025-04-27T21:50:15 doc: Prepare for conversion to Doxygen Fix many params in internal functions (not really necessary but Doxygen warns about that in XML mode). Fix formatting in a few corner cases that automatic conversion can't handle. Rearrange some DOC_DISABLE blocks.
Nick Wellnhofer e91061eb 2025-03-14T01:49:22 hash: Fix false positive from -fanalyzer
Nick Wellnhofer 3d37ff84 2025-03-04T15:10:09 globals: Also use global state struct if threads are disabled
Nick Wellnhofer cd491ac0 2025-02-02T13:13:20 dict: Handle ENOSYS from getentropy gracefully Also add some comments. Should fix #854.
Nick Wellnhofer e1657f3f 2024-07-22T14:33:14 build: Use AC_CHECK_DECLS/check_symbol_exists for getentropy This assumes that getentropy is declared in sys/random.h. Should fix issues on iOS. See #774.
Nick Wellnhofer 72886980 2024-07-15T14:35:47 error: Add helper functions to print errors and abort
Nick Wellnhofer 84a4f84c 2024-06-22T02:11:24 build: Don't check for required headers and functions Unless we are on Windows, the following POSIX headers are required. They're part of the earliest POSIX specs and it doesn't make sense to check for them. - fcntl.h - unistd.h - sys/stat.h - sys/time.h On Windows, io.h, fcntl.h and sys/stat.h are always available.
Nick Wellnhofer e75e878e 2024-05-20T13:58:22 doc: Update and fix documentation
Nick Wellnhofer 595ee5bc 2024-02-14T13:58:14 dict: Include unistd.h for getentropy
Nick Wellnhofer 9c2c87b5 2023-12-24T15:33:12 dict: Move local RNG state to global state Don't use TLS variables directly.
Nick Wellnhofer 2e9e758d 2023-12-24T14:27:46 dict: Get random seed from system PRNG
makise-homura c1e9f761 2023-11-09T01:44:09 Avoid EDG -Woverflow warnings on truncating conversions by manually truncating operand
Nick Wellnhofer 272cb223 2023-11-20T14:22:18 dict: Fix '__thread' before 'static' When used with extern or static, __thread must appear immediately after the other storage class specifier. Fixes #621.
Nick Wellnhofer 58598494 2023-11-04T23:47:33 parser: Fix combination of hash values This bug resulted in a stuck bit in hash values which can have a severe performance impact.
Nick Wellnhofer a7b03795 2023-11-04T19:04:23 doc: Minor fixes for apibuild.py
Nick Wellnhofer 7dfcea03 2023-10-11T14:19:04 dict: Fix integer overflow in xmlDictAddString Short-lived regression. Older versions didn't check for integer overflow, but limited name length to INT_MAX / 2. Reintroduce this limit. Found by OSS-Fuzz.
Nick Wellnhofer 71aae4e9 2023-10-02T14:42:51 dict: Compare strings with strncmp Using memcmp can result in OOB reads. Short-lived regression found by OSS-Fuzz.
Nick Wellnhofer f0a703da 2023-09-30T17:05:47 dict: Fix null-deref with empty subdict Short lived regression found by OSS-Fuzz.
Nick Wellnhofer 61e29b69 2023-09-30T17:02:46 malloc-fail: Grow hash tables before making allocations Fix short-lived memory leak found by OSS-Fuzz.
Nick Wellnhofer 19161bab 2023-09-25T14:00:48 dict: Internal API to look up hash values
Nick Wellnhofer d147f564 2023-09-11T05:37:55 dict: Rewrite dictionary hash table code Rewrite the dictionary hash table to use open addressing with Robin Hood probing. See previous commit.
Nick Wellnhofer 1425d8f6 2023-09-16T19:08:10 dict: Separate RNG code
Nick Wellnhofer 699299ca 2023-09-20T18:54:39 globals: Stop including globals.h
Nick Wellnhofer 05c28305 2023-09-04T15:50:22 dict: Stop using uint32_t stdint.h is a C99 header.
Nick Wellnhofer f45abbd3 2023-09-04T15:31:04 dict: Fix integer overflow of string lengths Fixes #546.
Nick Wellnhofer edc2dd48 2023-09-04T16:07:23 dict: Update hash function Update hash function from classic Jenkins OAAT (dict.c) and a variant of DJB2 (hash.c) to "GoodOAAT" taken from the SMHasher repo. This hash function passes all SMHasher tests.
Nick Wellnhofer c5989473 2023-09-01T14:52:11 dict: Use thread-local storage for PRNG state
Nick Wellnhofer 57cfd221 2023-09-01T14:52:04 dict: Use xoroshiro64** as PRNG Stop using rand_r. This enables hash randomization on all platforms.
Nick Wellnhofer 6d7aaaa8 2023-09-01T14:51:55 dict: Tune hash table growth Introduce load factor as main trigger and increase MAX_HASH_LEN. This should make growth behavior more predictable. Raise size limit to INT_MAX. This avoids quadratic behavior with larger tables.
Nick Wellnhofer 7f3f3f11 2023-05-03T03:20:14 dict: Raise MAX_DICT_HASH limit This fixes quadratic behavior with large dictionaries. Also rework testdict.c to support tests with larger dictionaries.
Nick Wellnhofer 547edbf1 2023-04-07T11:49:27 [CVE-2023-29469] Hashing of empty dict strings isn't deterministic When hashing empty strings which aren't null-terminated, xmlDictComputeFastKey could produce inconsistent results. This could lead to various logic or memory errors, including double frees. For consistency the seed is also taken into account, but this shouldn't have an impact on security. Found by OSS-Fuzz. Fixes #510.
Nick Wellnhofer 8c2e508b 2023-03-12T14:45:14 gitlab-ci: Enable all "integer" sanitizers
Nick Wellnhofer 65d381f3 2022-11-24T20:54:18 threads: Allocate mutexes statically
Nick Wellnhofer 9ef80ff1 2022-11-25T12:33:25 memory: Remove xmlDictInitialized Call xmlInitParser when creating dicts instead.
Nick Wellnhofer ed053c50 2022-11-25T12:27:14 dict: Make init/cleanup functions private
Nick Wellnhofer b6f1298a 2022-10-24T20:47:10 warnings: Remove set-but-unused variables Fixes compiler warnings with clang 15.
Nick Wellnhofer ad338ca7 2022-09-01T01:18:30 Remove explicit integer casts Remove explicit integer casts as final operation - in assignments - when passing arguments - when returning values Remove casts - to the same type - from certain range-bound values The main motivation is that these explicit casts don't change the result of operations and only render UBSan's implicit-conversion checks useless. Removing these casts allows UBSan to detect cases where truncation or sign-changes occur unexpectedly. Document some explicit casts as truncating and add a few missing ones.
Nick Wellnhofer 0f568c0b 2022-08-26T01:22:33 Consolidate private header files Private functions were previously declared - in header files in the root directory - in public headers guarded with IN_LIBXML - in libxml.h - redundantly in source files that used them. Consolidate all private header files in include/private.
Nick Wellnhofer 3241c47c 2022-03-06T14:58:04 Use non-recursive mutex in dict.c The mutex is never locked recursively.
Nick Wellnhofer 40483d0c 2022-03-06T13:55:48 Deprecate module init and cleanup functions These functions shouldn't be part of the public API. Most init functions are only thread-safe when called from xmlInitParser. Global variables should only be cleaned up by calling xmlCleanupParser.
Nick Wellnhofer 72119afe 2022-03-02T01:14:08 Don't check for standard C89 library functions Don't check for - fprintf - localtime - printf - rand - sprintf - srand - sscanf - strftime - time - vfprintf - vsprintf If the C99 functions snprintf and vsnprintf are missing, Trio is enabled.
Nick Wellnhofer 776d15d3 2022-03-02T00:29:17 Don't check for standard C89 headers Don't check for - ctype.h - errno.h - float.h - limits.h - math.h - signal.h - stdarg.h - stdlib.h - string.h - time.h Stop including non-standard headers - malloc.h - strings.h
Nick Wellnhofer 346c3a93 2022-02-20T18:46:42 Remove elfgcchack.h The same optimization can be enabled with -fno-semantic-interposition since GCC 5. clang has always used this option by default.
Nick Wellnhofer 20c60886 2020-03-08T17:19:42 Fix typos Resolves #133.
Ranier Vilela 3c8a3e99 2019-11-07T12:59:10 Use random seed in xmlDictComputeFastKey xmlDictComputeFastKey is only used for small tables, so this shouldn't be a security problem.
Nick Wellnhofer b88ae6d2 2019-10-14T15:38:28 Avoid ignored attribute warnings under GCC GCC doesn't support the unsigned-integer-overflow sanitizer.
Jared Yanovich 2a350ee9 2019-09-30T17:04:54 Large batch of typo fixes Closes #109.
Nick Wellnhofer 44e7a0d5 2019-05-16T21:17:28 Annotate functions with __attribute__((no_sanitize))
Nick Wellnhofer fa3166c2 2019-04-12T12:03:04 Disable hash randomization when fuzzing Use the FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION macro proposed by libFuzzer.
J. Peter Mugaas d2c329a9 2017-10-21T13:49:31 Fix -Wimplicit-fallthrough warnings Add "falls through" comments to quench implicit-fallthrough warnings which are enabled by -Wextra under GCC 7.
Nick Wellnhofer 6472dfe3 2017-10-09T16:50:57 Fix a couple of warnings in dict.c and threads.c Only visible on Windows.
Nick Wellnhofer e3890546 2017-10-09T00:20:01 Fix the Windows header mess Don't include windows.h and wsockcompat.h from config.h but only when needed. Don't define _WINSOCKAPI_ manually. This was apparently done to stop windows.h from including winsock.h which is a problem if winsock2.h wasn't included first. But on MinGW, this causes compiler warnings. Define WIN32_LEAN_AND_MEAN instead which has the same effect. Always use the compiler-defined _WIN32 macro instead of WIN32.
Nick Wellnhofer 8bbe4508 2017-06-17T16:15:09 Spelling and grammar fixes Fixes bug 743172, bug 743489, bug 769632, bug 782400 and a few other misspellings.
Jan Pokorný bb654feb 2016-04-13T16:56:07 Fix typos: dictio{ nn -> n }ar{y,ies} Signed-off-by: Jan Pokorný <jpokorny@redhat.com>
David Drysdale 6360a31a 2015-11-20T10:47:12 CVE-2015-7497 Avoid an heap buffer overflow in xmlDictComputeFastQKey For https://bugzilla.gnome.org/show_bug.cgi?id=756528 It was possible to hit a negative offset in the name indexing used to randomize the dictionary key generation Reported and fix provided by David Drysdale @ Google
Daniel Veillard 5fe9e9ed 2013-04-05T23:10:41 Remove risk of lockup in dictionary initialization Reported by Petr Sumbera <petr.sumbera@oracle.com> Two threads entering xmlInitializeDict concurently could lead to a lockup due to multiple initializations of the lock used. To avoid this problem move this to a new private function called from xmlOnceInit() and deprecate the old initalizer. Since threaded programs must call xmlInitParser() and this will lead to dereference of private data and the call to xmlOnceInit() guaranteed to be unique this should be safe now.
Wouter Van Rooy e7715a59 2012-09-14T14:39:42 rand_seed should be static in dict.c For https://bugzilla.gnome.org/show_bug.cgi?id=683933 rand_seed should be a static variable in dict.c We ran into a problem with another library that exports rand_seed as a function. Combined with 2.7.8 this was not a problem but later versions have this problem.
Patrick Gansterer fd4f6fdd 2012-08-13T17:54:20 Fix non __GNUC__ build For https://bugzilla.gnome.org/show_bug.cgi?id=681590 Length member of _xmlDictEntry is called "len" and not "l"
Daniel Veillard 7c693dad 2012-07-25T16:32:18 Cleanups and new limit APIs for dictionaries * include/libxml/dict.h dict.c: adding 2 new functions xmlDictGetUsage and xmlDictSetLimit allowing to review the amount of memory allocated for dictionary strings. Aslo cleanup of various signed int used as size values in the code.
Daniel Veillard ee8f1d4c 2012-05-21T11:16:12 Cleanups before 2.8.0-rc2 new symbols, a missing comment and a fix on symbol release
Daniel Veillard 379ebc1d 2012-05-18T15:41:31 Cleanup on randomization tsan reported that rand() is not thread safe, so create a thread safe wrapper, use rand_r() if available. Consolidate the function, initialization and cleanup in dict.c and make sure it is initialized in xmlInitParser()
Rob Richards aa0be5f2 2012-05-09T12:42:51 fix windows build. ifdef addition from bug 666491 makes no sense
Thomas Lemm 066c6977 2012-05-09T18:27:04 Allow to compile with Visual Studio 2010 For https://bugzilla.gnome.org/show_bug.cgi?id=666491 This patch adds project files to compile and debug libxml2 using Visual Studio 2010. Only few minor changes have been made to the actual source code. This patch also requires for the iconv package to be compiled with visual studio 2010 which has been submitted to the iconv project (see: https://savannah.gnu.org/bugs/?35088)
Daniel Veillard 8973d58b 2012-02-04T19:07:44 Add hash randomization to hash and dict structures Following http://www.ocert.org/advisories/ocert-2011-003.html it seems that having hash randomization might be a good idea when using XML with untrusted data * configure.in: lookup for rand, srand and time * dict.c: add randomization to dictionaries hash tables * hash.c: add randomization to normal hash tables
Daniel Veillard 594e5dfb 2009-09-07T14:58:47 Chasing dead assignments reported by clang-scan * SAX2.c dict.c error.c hash.c nanohttp.c parser.c python/libxml.c relaxng.c runtest.c tree.c valid.c xinclude.c xmlregexp.c xmlsave.c xmlschemas.c xpath.c xpointer.c: mostly removing unneded affectations, but this led to a few real bugs and some part not yet understood (relaxng/interleave)
Daniel Veillard 7f4547cd 2008-10-03T07:58:23 preparing the release of 2.7.2 fix the Solaris portability issue * configure.in doc/* NEWS: preparing the release of 2.7.2 * dict.c: fix the Solaris portability issue * parser.c: additional cleanup on #554660 fix * test/ent13 result/ent13* result/noent/ent13*: added the example in the regression test suite. * HTMLparser.c: handle leading BOM in htmlParseElement() Daniel svn path=/trunk/; revision=3799
Rob Richards 117baa07 2008-08-10T17:07:33 fix non GNUC builds. * dict.c: fix non GNUC builds. svn path=/trunk/; revision=3771
Daniel Veillard d68f8912 2008-08-08T10:09:19 added a program to regression test the dictionary code improve the lookup * testdict.c: added a program to regression test the dictionary code * dict.c: improve the lookup efficiency by caching the key. Daniel svn path=/trunk/; revision=3768
Daniel Veillard ffda65f0 2008-08-07T16:33:49 chased and found a couple of nasty issues Daniel * dict.c: chased and found a couple of nasty issues Daniel svn path=/trunk/; revision=3767
Daniel Veillard 424785e7 2008-08-06T09:35:25 change the big key algorithm to work properly with QName too, fix a bug * dict.c: change the big key algorithm to work properly with QName too, fix a bug with dict size and sub dictionaries Daniel svn path=/trunk/; revision=3764
Rob Richards b6b2ee1a 2008-05-03T12:34:25 check for stdint.h and define types when using MSVC * dict.c: check for stdint.h and define types when using MSVC svn path=/trunk/; revision=3742
Daniel Veillard e9100a58 2008-04-22T08:28:50 improvement on the hashing of the dictionnary, with visible speed up as * dict.c: improvement on the hashing of the dictionnary, with visible speed up as the number of strings in the hash increases, work from Stefan Behnel Daniel svn path=/trunk/; revision=3739
Daniel Veillard b242b088 2008-02-08T09:56:31 applied patch from Florent Guilian to remove an useless mutex in the * dict.c: applied patch from Florent Guilian to remove an useless mutex in the xmlDict structure. older, not commited ... * SAX2.c: another leak reported by Ashwin * xinclude.c: fixed the behaviour when XIncluding a fragment of the current document, patch from Chris Ryan Daniel svn path=/trunk/; revision=3686
Daniel Veillard 5d4644ef 2005-04-01T13:11:58 revamped the elfgcchack.h format to cope with gcc4 change of aliasing * doc/apibuild.py doc/elfgcchack.xsl: revamped the elfgcchack.h format to cope with gcc4 change of aliasing allowed scopes, had to add extra informations to doc/libxml2-api.xml to separate the header from the c module source. * *.c: updated all c library files to add a #define bottom_xxx and reimport elfgcchack.h thereafter, and a bit of cleanups. * doc//* testapi.c: regenerated when rebuilding the API Daniel
William M. Brack 4e1c2db8 2005-02-11T10:58:55 fixed compilation warning changed xmlWarningMsg so ctxt->errNo is not set * dict.c: fixed compilation warning * parser.c: changed xmlWarningMsg so ctxt->errNo is not set * xmllint.c: changed to return non-zero status if error on xinclude processing * xmlsave.c: minor deletion of a redundant condition statement
Daniel Veillard 2ae13382 2005-01-25T23:45:06 fixing the way testapi.c is generated, fixes bug #161386 fix a comment * Makefile.am testapi.c doc/Makefile.am: fixing the way testapi.c is generated, fixes bug #161386 * dict.c: fix a comment typo * elfgcchack.h doc/*: regenerated Daniel
Daniel Veillard 1441251f 2005-01-21T23:53:26 a single lock version mostly avoid the cost penalty of the lock in case of * dict.c parser.c include/libxml/dict.h: a single lock version mostly avoid the cost penalty of the lock in case of low parallelism, so applying that version instead. Daniel
Daniel Veillard 1bb16a18 2005-01-21T16:55:41 patch from Gary Coady to fix a race in dict reference counting in * dict.c: patch from Gary Coady to fix a race in dict reference counting in multithreaded apps. Daniel
William M. Brack ad0e67c5 2004-12-01T14:35:10 fixed up some gcc warnings, no change to logic. New macro XML_CAST_FPTR to * dict.c, xpath.c, include/libxml/hash.h: fixed up some gcc warnings, no change to logic. New macro XML_CAST_FPTR to circumvent gcc warnings on function pointer <-> object pointer (a hack).
Daniel Veillard 6bb3e86d 2004-11-24T12:39:00 added xmlDictExists() to the dictionnary interface. applying * dict.c include/libxml/dict.h: added xmlDictExists() to the dictionnary interface. * xmlreader.c: applying xmlTextReaderHasAttributes fix for namespaces from Rob Richards Daniel
William M. Brack bf5cf219 2004-08-31T06:47:17 fixed bug introduced during OOM fixup causing problems with default * SAX2.c: fixed bug introduced during OOM fixup causing problems with default namespace when a named prefix with the same href was present (reported on the mailing list by Karl Eichwalder. * xmlstring.c: modified xmlCheckUTF8 with suggested code from Julius Mittenzwei. * dict.c: added a typecast to try to avoid problem reported by Pascal Rodes.
Daniel Veillard 4773df2a 2004-01-23T13:15:13 added io1.c an example ox xmlIO usage and io1.res test result, fixed a * doc/examples/*: added io1.c an example ox xmlIO usage and io1.res test result, fixed a awful lot of memory leaks showing up in testWriter.c, changed the examples and the Makefiles to test memory leaks. * xmlwriter.c: fixed a memory leak * Makefile.am: run the doc/examples regression tests as part of make tests * xpath.c include/libxml/xpath.h: added xmlXPathCtxtCompile() to compile an XPath expression within a context, currently the goal is to be able to reuse the XSLT stylesheet dictionnary, but this opens the door to others possible optimizations. * dict.c include/libxml/dict.h: added xmlDictCreateSub() which allows to build a new dictionnary based on another read-only dictionnary. This is needed for XSLT to keep the stylesheet dictionnary read-only while being able to reuse the strings for the transformation dictionnary. * xinclude.c: fixed a dictionnar reference counting problem occuring when document parsing failed. * testSAX.c: adding option --repeat for timing 100times the parsing * doc/* : rebuilt all the docs Daniel
Daniel Veillard c82c57e6 2004-01-12T16:24:34 some parser optimizations, xmllint --memory --timing --repeat --stream * dict.c parser.c xmlstring.c: some parser optimizations, xmllint --memory --timing --repeat --stream ./db10000.xml went down from 16.5 secs to 15.5 secs. Daniel
Daniel Veillard e96a2a4b 2003-09-24T21:23:56 adding repeated parsing and validating tests make the new DOM tree * Makefile.am: adding repeated parsing and validating tests * SAX2.c parser.c tree.c include/libxml/parser.h: make the new DOM tree building interfaces use the dictionary from the parsing context to build the element and attributes names as well as formatting spaces and short text nodes * include/libxml/dict.h dict.c: added some reference counting for xmlDictPtr because they can be shared by documents and a parser context. * xmlreader.c: a bit of cleanup, remove the specific tree freeing functions and use the standard ones now. * xmllint.c: add --nodict * python/libxml.c: fix a stupid bug so that ns() works on attribute nodes. Daniel
Daniel Veillard e72c508c 2003-09-19T12:44:05 preparing a 2.6.0-beta2 release avoid a warning avoid duplicate code in * configure.in: preparing a 2.6.0-beta2 release * xmlIO.c: avoid a warning * tree.c: avoid duplicate code in xmlReplaceNode as pointed out by Chris Ryland * include/libxml/dict.h: add a QName access lookup to the dictionary. * xmlreader.c include/libxml/xmlreader.h: adding const access based on the dictionary interface for string read from the reader, the node content access is still TODO, it's too different Daniel
Daniel Veillard c44cfdd7 2003-09-18T10:12:02 the last patch broke unicity of returned strings, removed Daniel * dict.c: the last patch broke unicity of returned strings, removed Daniel
Daniel Veillard 536fad5a 2003-09-18T10:05:56 valgrind found a newly introduced bug Daniel * dict.c: valgrind found a newly introduced bug Daniel
Daniel Veillard ccc4d2b6 2003-09-17T21:27:31 two small improvements Daniel * dict.c xmlreader.c: two small improvements Daniel
Daniel Veillard 81514ba4 2003-09-16T23:17:26 do string allocations in large pools, allowing to find if a string pertain * dict.c include/libxml/dict.h: do string allocations in large pools, allowing to find if a string pertain to a dict quickly * xmllint.c: fix --stream --repeat --timing * Makefile.am: the testThreads run output should be seen. Daniel
Daniel Veillard 07cb8226 2003-09-10T10:51:05 Time to commit 3 days of work rewriting the parser internal, fixing bugs and migrating to SAX2 interface by default. There is some work letf TODO, like namespace validation and attributes normalization (this break C14N right now) * Makefile.am: fixed the test rules * include/libxml/SAX2.h include/libxml/parser.h include/libxml/parserInternals.h SAX2.c parser.c parserInternals.c: changing the parser, migrating to SAX2, adding new interface to switch back to SAX1 or initialize a SAX block for v1 or v2. Most of the namespace work is done below SAX, as well as attribute defaulting * globals.c: changed initialization of the default SAX handlers * hash.c tree.c include/libxml/hash.h: added QName specific handling * xmlIO.c: small fix * xmllint.c testSAX.c: provide a --sax1 switch to test the old version code path * result/p3p result/p3p.sax result/noent/p3p test/p3p: the new code pointed out a typo in a very old test namespace Daniel
Daniel Veillard 0fb18935 2003-09-07T09:14:37 allow to give -1 for undefined length in lookups first round of work on * dict.c: allow to give -1 for undefined length in lookups * include/libxml/parser.h parser.c parserInternals.c testSAX.c: first round of work on the new SAX2 interfaces, the API will change but commiting before changing for historical reference. Daniel
Daniel Veillard 1af9a41f 2003-08-20T22:54:39 Adding new version of the SAX interface, it's not there yet, currently * Makefile.am SAX2.c include/libxml/Makefile.am include/libxml/SAX2.h: Adding new version of the SAX interface, it's not there yet, currently just preparing the work * globals.c parser.c SAX.c include/libxml/SAX.h include/libxml/globals.h include/libxml/parser.h: doing some refactoring of the SAXv1 interfaces, obsoleting a bunch of them while keeping functionalities, preparing SAX2 integration. * dict.c: small cleanup. Daniel
Daniel Veillard 6155d8aa 2003-08-19T15:01:28 optimization when freeing hash tables. some tuning of buffer allocations * dict.c hash.c: optimization when freeing hash tables. * parser.c xmlIO.c include/libxml/tree.h: some tuning of buffer allocations * parser.c parserInternals.c include/libxml/parser.h: keep a single allocated block for all the attributes callbacks, avoid useless malloc()/free() * tree.c: do not realloc() when growing a buffer if the buffer ain't full, malloc/memcpy/free avoid copying memory. Daniel
Daniel Veillard 2fdbd32d 2003-08-18T12:15:38 new dictionary module to keep a single instance of the names used by the * dict.c include/libxml/dict.h Makefile.am include/libxml/Makefile.am: new dictionary module to keep a single instance of the names used by the parser * DOCBparser.c HTMLparser.c parser.c parserInternals.c valid.c: switched all parsers to use the dictionary internally * include/libxml/HTMLparser.h include/libxml/parser.h include/libxml/parserInternals.h include/libxml/valid.h: Some of the interfaces changed as a result to receive or return "const xmlChar *" instead of "xmlChar *", this is either insignificant from an user point of view or when the returning value changed, those function are really parser internal methods that no user code should really change * doc/libxml2-api.xml doc/html/*: the API interface changed and the docs were regenerated Daniel