baserock-morphs:libxml2.git
7 years agoRelease of libxml2-2.7.5 v2.7.5
Daniel Veillard [Thu, 24 Sep 2009 16:38:57 +0000 (18:38 +0200)]
Release of libxml2-2.7.5

* configure.in doc/xml.html: updated
* doc/libxml2.xsa doc/xml.html python/setup.py: regenerated

7 years agoRestore behavior of --with-threads without argument
Andrew W. Nosenko [Thu, 24 Sep 2009 15:33:21 +0000 (17:33 +0200)]
Restore behavior of --with-threads without argument

* configure.in: restore behavior of --with-threads without argument as
  "enable threads support"

7 years agoFix memory leak when doc is NULL
Rob Richards [Thu, 24 Sep 2009 15:00:16 +0000 (11:00 -0400)]
Fix memory leak when doc is NULL
* xmlschemas.c: fix memory leak when doc is NULL

7 years ago595792 fixing a RelaxNG bug introduced in 2.7.4
Daniel Veillard [Thu, 24 Sep 2009 09:31:48 +0000 (11:31 +0200)]
595792 fixing a RelaxNG bug introduced in 2.7.4

* relaxng.c: refs definitions added from inported schemas should not
  be processed as refs from the main schemas
* test/relaxng/595792* result/relaxng/595792*: add the test to the
  regression suite

7 years agoAdding symbols.xml to EXTRA_DIST
Daniel Veillard [Wed, 23 Sep 2009 16:32:42 +0000 (18:32 +0200)]
Adding symbols.xml to EXTRA_DIST

7 years agoFix a Relaxng bug raised by libvirt test suite
Daniel Veillard [Wed, 23 Sep 2009 16:28:43 +0000 (18:28 +0200)]
Fix a Relaxng bug raised by libvirt test suite

* xmlregexp.c: other fixes in 2.7.4 raised this internal error
  when comparing ranges, this affects among others detection of
  the determinism
* test/relaxng/libvirt* result/relaxng/libvirt*: add a test case
  based on libvirt schemas and tests

8 years agoFix a parsing problem with little data at startup
Daniel Veillard [Tue, 15 Sep 2009 16:41:30 +0000 (18:41 +0200)]
Fix a parsing problem with little data at startup

* parser.c: inkscape extension loader (and possibly others) feed
  data to the parser very slowly, 0 at start, 4 bytes on first GROW
  and this broke after the fix for
  https://bugzilla.gnome.org/show_bug.cgi?id=566012
  http://git.gnome.org/cgit/libxml2/commit/?id=7e385bd4e28a0cc12b6b26ed178c620e3c3ab8d8
  leading to another bug
  https://bugzilla.redhat.com/show_bug.cgi?id=523002
  this detects the situation and GROW when needed for proper processing.

8 years agolink python module with python library
Frederic Crozat [Sat, 12 Sep 2009 16:02:40 +0000 (18:02 +0200)]
link python module with python library

* configure.in python/Makefile.am: libxml2 python module wasn't linked
  with python library

8 years ago594874 Forgot an fclose in xmllint
Daniel Veillard [Fri, 11 Sep 2009 13:30:19 +0000 (15:30 +0200)]
594874 Forgot an fclose in xmllint

* xmllint.c: as pointed out by Pavol Rusnak, an fclose was missing
  in some case.

8 years agoRelease of libxml2-2.7.4 v2.7.4
Daniel Veillard [Thu, 10 Sep 2009 16:23:39 +0000 (18:23 +0200)]
Release of libxml2-2.7.4

* configure.in: new version
* libxml.spec.in: cleanup
* xmlregexp.c: fix a comment
* doc/apibuild.py: update
* doc/*: regenerate everything

8 years ago593857 try to work around thread pbm MinGW 4.4
Daniel Veillard [Thu, 10 Sep 2009 15:46:07 +0000 (17:46 +0200)]
593857 try to work around thread pbm MinGW 4.4

* threads.c: try to cope with HAVE_PTHREAD_H and HAVE_WIN32_THREADS
  being both defined and pthread_t being a non integer

8 years ago594514 memory leaks - duplicate initialization
MOD [Wed, 9 Sep 2009 17:03:13 +0000 (19:03 +0200)]
594514 memory leaks - duplicate initialization

* globals.c: xmlInitGlobals() might be called multiple times, leaking
  the xmlThrDefMutex value

8 years ago594250 rename ATTRIBUTE_ALLOC_SIZE to avoid clashes
Daniel Veillard [Wed, 9 Sep 2009 16:57:26 +0000 (18:57 +0200)]
594250 rename ATTRIBUTE_ALLOC_SIZE to avoid clashes

* include/libxml/xmlmemory.h include/libxml/xmlversion.h.in: rename it
  to LIBXML_ATTR_ALLOC_SIZE to avoid conflicts in public headers

8 years agoFix Windows build
Rob Richards [Wed, 9 Sep 2009 16:13:58 +0000 (12:13 -0400)]
Fix Windows build
* relaxng.c: fix windows build

8 years agoFix the globals.h to use XMLPUBFUN
Paul Smith [Mon, 7 Sep 2009 13:24:24 +0000 (15:24 +0200)]
Fix the globals.h to use XMLPUBFUN

* include/libxml/globals.h: in addition to the extern extern
  Paul Smith noted that XMLPUBFUN should be used instead of
  LIBXML_DLL_IMPORT

8 years agoProblem with extern extern in header
Daniel Veillard [Mon, 7 Sep 2009 13:20:24 +0000 (15:20 +0200)]
Problem with extern extern in header

* include/libxml/globals.h: LIBXML_DLL_IMPORT should not be
  followed by extern
* include/libxml/xmlmemory.h: fix the same problem but in a comment

8 years agoChasing dead assignments reported by clang-scan
Daniel Veillard [Mon, 7 Sep 2009 12:58:47 +0000 (14:58 +0200)]
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)

8 years agoA few more safety cleanup raised by scan
Daniel Veillard [Mon, 7 Sep 2009 10:15:08 +0000 (12:15 +0200)]
A few more safety cleanup raised by scan

* SAX2.c encoding.c parser.c xmlschemas.c: a few more safety checks
* relaxng.c: remove an unused intitialization

8 years agoFixing assorted potential problems raised by scan
Daniel Veillard [Mon, 7 Sep 2009 09:19:33 +0000 (11:19 +0200)]
Fixing assorted potential problems raised by scan

* encoding.c parser.c relaxng.c runsuite.c tree.c xmlreader.c
  xmlschemas.c: nothing really serious but better safe than sorry

8 years agoPotential uninitialized arguments raised by scan
Daniel Veillard [Sat, 5 Sep 2009 13:04:41 +0000 (15:04 +0200)]
Potential uninitialized arguments raised by scan

* parser.c: ctxt->sax2 is not supposed to change suring parsing
  but better safe than sorry and initialize prefix and URI used in
  SAX2 callbacks.

8 years agoFix a bunch of scan 'dead increments' and cleanup
Daniel Veillard [Sat, 5 Sep 2009 12:52:55 +0000 (14:52 +0200)]
Fix a bunch of scan 'dead increments' and cleanup

* HTMLparser.c c14n.c debugXML.c entities.c nanohttp.c parser.c
  testC14N.c uri.c xmlcatalog.c xmllint.c xmlregexp.c xpath.c:
  fix unused variables, or unneeded increments as well as a couple
  of space issues
* runtest.c: check for NULL before calling unlink()

8 years agoWrong block opening in htmlNodeDumpOutputInternal
Daniel Veillard [Wed, 2 Sep 2009 12:58:13 +0000 (14:58 +0200)]
Wrong block opening in htmlNodeDumpOutputInternal

* xmlsave.c: Jim Meyering ran clang on libxml2 and this is one of
  the error found, misplaced curly brace

8 years ago492317 Fix Relax-NG validation problems
Daniel Veillard [Mon, 31 Aug 2009 14:47:39 +0000 (16:47 +0200)]
492317 Fix  Relax-NG validation problems

* relaxng.c xmlregexp.c: a subtle problem when checking for compileable
  content model, if using the same elements in cases of choices. Handled
  by adding a special flag to the regexp compilation to detect
  transitions with different atoms using same strings.
* test/relaxng/492317* result/relaxng/492317*: add the test to the
  regression suite

8 years ago558452 fight with reg test and error report
Daniel Veillard [Wed, 26 Aug 2009 16:37:43 +0000 (18:37 +0200)]
558452 fight with reg test and error report

* relaxng.c: tiny fix and provide more context on some errors
* result/relaxng/558452_0* test/relaxng/558452*: add some regression
  tests for the bugs
* Makefile.am runtest.c: fight with the fact streaming error messages
  can differ due to missing node context

8 years ago558452 RNG compilation of optional multiple child
Daniel Veillard [Wed, 26 Aug 2009 16:35:29 +0000 (18:35 +0200)]
558452 RNG compilation of optional multiple child

* relaxng.c: don't assume there is a single define under a optional

8 years ago579746 XSD validation not correct / nilable groups
Daniel Veillard [Wed, 26 Aug 2009 15:24:31 +0000 (17:24 +0200)]
579746 XSD validation not correct / nilable groups

* xmlschemas.c: when a particle need to be processed via counted
  transition, if the group is nillable, the counting won't work, so
  keep track of nillable subset as they are built and generate the
  appropriate epsilon transitions as needed
* test/schemas/579746* result/schemas/579746*: add related test cases
  based on the bug report

8 years ago502960 provide namespace stack when parsing entity
Daniel Veillard [Wed, 26 Aug 2009 13:57:20 +0000 (15:57 +0200)]
502960 provide namespace stack when parsing entity

* parser.c: copy the entity stack
* SAX2.c: fix the warning message for default entities

8 years ago566012 part 2 fix regresion tests and push mode
Daniel Veillard [Wed, 26 Aug 2009 12:37:00 +0000 (14:37 +0200)]
566012 part 2 fix regresion tests and push mode

* test/utf16bebom.xml: regression test showed that this test case was
  broken but previous behaviour would not detect it !
* parser.c: fix 566012 for the push mode of the parser, tricky !
* test/ebcdic_566012.xml result//ebcdic_566012.xml*: add the test to the
  regression suite

8 years ago566012 autodetected encoding and encoding conflict
Daniel Veillard [Wed, 26 Aug 2009 09:38:49 +0000 (11:38 +0200)]
566012 autodetected encoding and encoding conflict

* encoding.c parser.c parserInternals.c: when we autodetect an encoding
  but it's actually not completely compatible with the one declared
  great care must be taken to not convert more than just the first line.
  Led to some refactoring, more private functions and a bit of cleanup.

8 years agoAdd -lnetwork for compiling on Haiku
Scott McCreary [Wed, 26 Aug 2009 07:55:24 +0000 (09:55 +0200)]
Add -lnetwork for compiling on Haiku

* configure.in: trivial addition of network to the AC_SEARCH_LIB check
  for setsockopt.

8 years ago584220 xpointer(/) and xinclude problems
Daniel Veillard [Tue, 25 Aug 2009 17:24:15 +0000 (19:24 +0200)]
584220 xpointer(/) and xinclude problems

* xinclude.c: xpointer(/) in xinclude could lead to sub-document nodes
  and also fixed the code to inherit the dictionary from the embedding
  document

8 years ago587663 Incorrect Attribute-Value Normalization
Daniel Veillard [Tue, 25 Aug 2009 15:18:39 +0000 (17:18 +0200)]
587663 Incorrect Attribute-Value Normalization

* parser.c: when replacing entities and that the entity is CDATA and
  reference entities then white space character in replacement text
  need to be replaced by 0x20
* result/noent/att10: correct the output of the associated regression
  test

8 years ago444994 HTML chunked failure for attribute with <>
Daniel Veillard [Tue, 25 Aug 2009 12:42:16 +0000 (14:42 +0200)]
444994 HTML chunked failure for attribute with <>

* HTMLparser.c: fix htmlParseLookupSequence to not save ctxt->checkIndex
  when the current buffer ends within an attribute value, as this
  information would be missed in next pass.

8 years agoRuntest portability patch for Solaris
Tim Rice [Tue, 25 Aug 2009 10:38:29 +0000 (12:38 +0200)]
Runtest portability patch for Solaris

* runtest.c: use defined(__sun) instead of defined(solaris)

8 years agoFix end of buffer char being split in XML parser
Daniel Veillard [Tue, 25 Aug 2009 09:30:34 +0000 (11:30 +0200)]
Fix end of buffer char being split in XML parser

* parserInternals.c: similar patch to previous, reset cur on GROW
  in xmlNextChar and xmlCurrentChar

8 years agoNon ASCII character may be split at buffer end
Adiel Mittmann [Tue, 25 Aug 2009 09:27:13 +0000 (11:27 +0200)]
Non ASCII character may be split at buffer end

* HTMLparser.c: make sure when we call xmlParserInputGrow in
  htmlCurrentChar, to reset the current pointer

8 years agoRegenerated API and symbols
Daniel Veillard [Mon, 24 Aug 2009 17:47:00 +0000 (19:47 +0200)]
Regenerated API and symbols

* doc/Makefile.am: make the check for symbols pbm a make api failure
* doc/symbols.xml: added xmlXIncludeProcessTreeFlagsData
* doc//* elfgcchack.h libxml2.syms testapi.c: regenerated

8 years ago440226 Add xmlXIncludeProcessTreeFlagsData API
Stefan Behnel [Mon, 24 Aug 2009 17:45:54 +0000 (19:45 +0200)]
440226 Add xmlXIncludeProcessTreeFlagsData API

* xinclude.c include/libxml/xinclude.h: new function similar to
  xmlXIncludeProcessFlagsData but operating on a subtree

8 years ago572129 speed up parasing of large HTML text nodes
Markus Kull [Mon, 24 Aug 2009 17:00:23 +0000 (19:00 +0200)]
572129 speed up parasing of large HTML text nodes

* HTMLparser.c: use a different lookup function htmlParseLookupChars()
  to avoid the quadratic behaviour

8 years agoRemove a pedantic warning
Daniel Veillard [Mon, 24 Aug 2009 16:45:33 +0000 (18:45 +0200)]
Remove a pedantic warning

8 years agoFix HTML parsing with 0 character in CDATA
Daniel Veillard [Mon, 24 Aug 2009 16:16:56 +0000 (18:16 +0200)]
Fix HTML parsing with 0 character in CDATA

* HTMLparser.c: 0 before the end of the input need some special case
  handling, raise the error and return a space instead

8 years agoRegenerate symbols and API after previous patches
Daniel Veillard [Mon, 24 Aug 2009 15:39:07 +0000 (17:39 +0200)]
Regenerate symbols and API after previous patches

* doc/symbols.xml: new global data xmlStructuredErrorContext
* doc/checkapisym.xsl: slightly improve output
* doc/* libxml2.syms win32/libxml2.def.src: regenerated the API

8 years agoFix SetGenericErrorFunc and SetStructured clash
Wang Lam [Mon, 24 Aug 2009 15:34:25 +0000 (17:34 +0200)]
Fix SetGenericErrorFunc and SetStructured clash

* include/libxml/globals.h globals.c global.data: define a new global
  variable (per thread) for structured error reporting, to not conflict
  with generic one
* error.c: when defined use the structured error report over any generic
  one

8 years ago566012 Incomplete EBCDIC parsing support
Martin Kögler [Mon, 24 Aug 2009 14:47:48 +0000 (16:47 +0200)]
566012  Incomplete EBCDIC parsing support

* encoding.c: the iconv converter is sometimes only found as "EBCDIC-US"

8 years agoSmall patch to accomodate the Haiku OS
Scott McCreary [Mon, 24 Aug 2009 14:35:35 +0000 (16:35 +0200)]
Small patch to accomodate the Haiku OS

* configure.in: keep M_LIBS to empty

8 years ago555833 always use rm -f in uninstall-local
Daniel Veillard [Mon, 24 Aug 2009 12:23:32 +0000 (14:23 +0200)]
555833 always use rm -f in uninstall-local

* Makefile.am: so that make clean doesn't fail in some circumstances

8 years ago544910 typo: "renciliateNs"
Leonid Evdokimov [Mon, 24 Aug 2009 12:08:43 +0000 (14:08 +0200)]
544910 typo: "renciliateNs"

* python/libxml.py: typo on a comment

8 years ago542394 xmlRegisterOutputCallbacks MAX_INPUT_CALLBACK
Daniel Veillard [Mon, 24 Aug 2009 11:52:23 +0000 (13:52 +0200)]
542394 xmlRegisterOutputCallbacks MAX_INPUT_CALLBACK

* xmlIO.c: trivial fix, wrong constant

8 years ago541335 HTML avoid creating 2 head or 2 body element
Daniel Veillard [Mon, 24 Aug 2009 10:50:23 +0000 (12:50 +0200)]
541335 HTML avoid creating 2 head or 2 body element

* HTMLparser.c: check when we see an head or a body tag and avoid
  autogenerating them
* include/libxml/parser.h: the values for ctxt->html change depending
  on the head or body tags being seen

8 years ago541237 error correcting missing end tags in HTML
Daniel Veillard [Mon, 24 Aug 2009 09:59:51 +0000 (11:59 +0200)]
541237 error correcting missing end tags in HTML

* HTMLparser.c: make sure /p closes the FONTSTYLE list of elements

8 years agoFix python regression test after 583439 cleanup
Daniel Veillard [Mon, 24 Aug 2009 09:59:07 +0000 (11:59 +0200)]
Fix python regression test after 583439 cleanup

8 years agoAdd VxWorks to list of OSes
Daniel Veillard [Mon, 24 Aug 2009 09:58:20 +0000 (11:58 +0200)]
Add VxWorks to list of OSes

8 years ago584605 package VxWorks folder in the distribution
Daniel Veillard [Mon, 24 Aug 2009 08:15:13 +0000 (10:15 +0200)]
584605 package VxWorks folder in the distribution

* Makefile.am: as Igor Novoseltsev pointed out this is missing from
  the distro

8 years ago583439 missing line numbers in push mode
Daniel Veillard [Sun, 23 Aug 2009 13:44:48 +0000 (15:44 +0200)]
583439 missing line numbers in push mode

* parser.c: use the line number stored in the node itself if present
  for end of tag line error reports

8 years ago587867 xmllint --html --xmlout serializing as HTML
Daniel Veillard [Sun, 23 Aug 2009 13:31:18 +0000 (15:31 +0200)]
587867 xmllint --html --xmlout serializing as HTML

* xmllint.c: one option was needed after the switch to the new save API

8 years ago559501 avoid select and use poll for nanohttp
Raphael Prevost [Sun, 23 Aug 2009 11:11:01 +0000 (13:11 +0200)]
559501 avoid select and use poll for nanohttp

* config.h.in configure.in: detect availability of poll() and poll.h
* nanohttp.c: switch to use poll instead of select() when possible to
  avoid out of fd set memory errors on very large fds

8 years ago559410 - Regexp bug on (...)? constructs
Daniel Veillard [Sat, 22 Aug 2009 16:56:01 +0000 (18:56 +0200)]
559410 -  Regexp bug on (...)? constructs

* xmlregexp.c: fix a regexp bug on some (...)? constructs
* test/schemas/nvdcve* result/schemas/nvdcve*: add the tests to the
  regression suite

8 years agoFix a small problem on previous HTML parser patch
Daniel Veillard [Sat, 22 Aug 2009 15:58:31 +0000 (17:58 +0200)]
Fix a small problem on previous HTML parser patch

8 years ago574017 Realloc too expensive on most platform
Daniel Veillard [Sat, 22 Aug 2009 13:18:31 +0000 (15:18 +0200)]
574017 Realloc too expensive on most platform

* tree.c: even on BSD there is too much of a penalty hit, to use
  the doubling buffer size strategy on all arches not just Windows.

8 years ago592430 - HTML parser runs into endless loop
Daniel Veillard [Sat, 22 Aug 2009 09:32:38 +0000 (11:32 +0200)]
592430 -  HTML parser runs into endless loop

* HTMLparser.c: fix the problem with detection erroring absolutely, and
  properly popping up the stack when in EOF, also passes XML_PARSE_HUGE
  when decoding options.

8 years ago447899 potential double free in xmlFreeTextReader
Daniel Veillard [Fri, 21 Aug 2009 16:40:50 +0000 (18:40 +0200)]
447899 potential double free in xmlFreeTextReader

* xmlreader.c: a document may still be referenced by fakenode,
  just free fakenode before freeing the document.

8 years ago446613 small validation bug mixed content with NS
Daniel Veillard [Fri, 21 Aug 2009 16:22:58 +0000 (18:22 +0200)]
446613 small validation bug mixed content with NS

* valid.c: fix a bug when valdating mixed content lists and some
  name use namespaces prefixes.
* result/valid/notes.xml* test/valid/dtds/notes.dtd * test/valid/notes.xml:
  add the test case to the regression suite

8 years agoFix the problem of revalidating a doc with RNG
Daniel Veillard [Fri, 21 Aug 2009 15:34:17 +0000 (17:34 +0200)]
Fix the problem of revalidating a doc with RNG

* relaxng.c: simply clear up the ->psvi of elements on the tree upon
  return, should not be needed for streaming APIs as tree are discarded

8 years agoRebuilt the API and regenerated docs
Daniel Veillard [Fri, 21 Aug 2009 13:20:55 +0000 (15:20 +0200)]
Rebuilt the API and regenerated docs

8 years agoAutoregenerate libxml2.syms automated checkings
Daniel Veillard [Fri, 21 Aug 2009 13:16:46 +0000 (15:16 +0200)]
Autoregenerate libxml2.syms automated checkings

* doc/symbols.xml: the source for all exported symbols
* doc/checkapisym.xsl: used to check libxml2-api.xml against exported
  symbols
* doc/syms.xsl: stylesheet regenerating libxml2.syms from symbols.xml
* doc/Makefile.am libxml2.syms: add the new rules and the generated
  version

8 years agoRegenerate the docuemtnation and update for git
Daniel Veillard [Thu, 20 Aug 2009 17:40:03 +0000 (19:40 +0200)]
Regenerate the docuemtnation and update for git

8 years agoAdd symbol versioning to libxml2 shared libs
Daniel Veillard [Thu, 20 Aug 2009 17:17:36 +0000 (19:17 +0200)]
Add symbol versioning to libxml2 shared libs

* libxml2.syms: the symbols with history, going back to 2.4.30
* Makefile.am configure.in: linking flags detection and use
* parser.c tree.c valid.c xpointer.c: various cleanup of functions
  which could be made static or simply discarded, not that many

8 years agoMake xmlRecoverDoc const (Martin Trappel)
Daniel Veillard [Thu, 20 Aug 2009 17:15:08 +0000 (19:15 +0200)]
Make xmlRecoverDoc const (Martin Trappel)

* include/libxml/parser.h parser.c: just make the parameter a const

8 years agoFix xmlKeepBlanksDefault to not break indent
Nick Wellnhofer [Thu, 20 Aug 2009 10:11:17 +0000 (12:11 +0200)]
Fix xmlKeepBlanksDefault to not break indent

* parserInternals.c: the old compatibility function xmlKeepBlanksDefault()
  should not reset xmlIndentTreeOutput to 0 because the default is 1

8 years agoFix the PHP search code
Daniel Veillard [Wed, 19 Aug 2009 15:51:25 +0000 (17:51 +0200)]
Fix the PHP search code

8 years ago512131 refs from externalRef part need to be added
Daniel Veillard [Fri, 14 Aug 2009 16:52:10 +0000 (18:52 +0200)]
512131 refs from externalRef part need to be added

* relaxng.c: refs from externalRef subschemas need to be added to
  the main schemas. Also fix a couple of problems with dangling
  references

8 years ago512131 crash in xmlRelaxNGValidateFullElement
Daniel Veillard [Fri, 14 Aug 2009 14:16:31 +0000 (16:16 +0200)]
512131 crash in xmlRelaxNGValidateFullElement

* relaxng.c: in some case we were not freeing the right data, also
  cleanup a few other things

8 years ago588441 allow '.' in HTML Names even if invalid
Daniel Veillard [Thu, 13 Aug 2009 08:10:29 +0000 (10:10 +0200)]
588441 allow '.' in HTML Names even if invalid

* HTMLparser.c: just allow '.' in htmlParseHTMLName list of characters

8 years ago582913 Fix htmlSetMetaEncoding() to be nicer
Daniel Veillard [Wed, 12 Aug 2009 21:03:23 +0000 (23:03 +0200)]
582913 Fix htmlSetMetaEncoding() to be nicer

* HTMLtree.c: htmlSetMetaEncoding should not destroy existing meta
  encoding elements, plus it should not change things at all if the
  encoding is the same. Also fixed htmlSaveFileFormat() to ask for
  change if outputing to UTF-8.

8 years agoBoth args of xmlStrcasestr are const
Daniel Veillard [Wed, 12 Aug 2009 21:02:08 +0000 (23:02 +0200)]
Both args of xmlStrcasestr are const

* include/libxml/xmlstring.h xmlstring.c: fix the constness of the
  second arg of xmlStrcasestr()

8 years ago579317 Try to find the HTML encoding information
Daniel Veillard [Wed, 12 Aug 2009 18:13:38 +0000 (20:13 +0200)]
579317 Try to find the HTML encoding information

* HTMLparser.c: if we hit an encoding error before parsing a potential
  <meta> with the info look in the input buffer to see if we can find
  it instead of forcing a blind switch to ISO-8859-1

8 years agoFix windows build
Rob Richards [Wed, 12 Aug 2009 15:41:27 +0000 (11:41 -0400)]
Fix windows build

8 years ago575875 don't output charset=html
Daniel Veillard [Wed, 12 Aug 2009 13:59:01 +0000 (15:59 +0200)]
575875 don't output charset=html

* HTMLtree.c: don't output charset=html in htmlSetMetaEncoding()
  as this is clearly a libxml2 only thingused for import only

8 years ago571271 fix semantic of xsd:all with minOccurs=0
Daniel Veillard [Wed, 12 Aug 2009 13:39:23 +0000 (15:39 +0200)]
571271 fix semantic of xsd:all with minOccurs=0

* xmlschemas.c: apparently we though it allowed any of the sub elements
  to be missing, and probably not what's expected from the spec, though
  it used to forbid it c.f.:
  http://lists.xml.org/archives/xml-dev/200109/msg00512.html
  asking HT for confirmation but it's likely that we were wrong on the
  semantic
* result/schemas/all_1_[367]*: this changes the output of soem of our
  internal regression tests

8 years agoTest case for 570702
Daniel Veillard [Wed, 12 Aug 2009 10:40:39 +0000 (12:40 +0200)]
Test case for 570702

8 years ago570702 fix a bug in regexp determinism checking
Daniel Veillard [Wed, 12 Aug 2009 10:21:42 +0000 (12:21 +0200)]
570702 fix a bug in regexp determinism checking

* xmlregexp.c: xmlFAComputesDeterminism was bugged as it removed as
  coalesced transitions on with sane source destination and atoms but
  not looking at counters

8 years ago567619 xmlValidateNotationUse missing param test
Daniel Veillard [Wed, 12 Aug 2009 08:39:29 +0000 (10:39 +0200)]
567619 xmlValidateNotationUse missing param test

* valid.c: this was raised by a testapi crash on solaris

8 years ago560524 – xmlTextReaderLocalName description
Daniel Veillard [Tue, 11 Aug 2009 16:31:42 +0000 (18:31 +0200)]
560524 – xmlTextReaderLocalName description

* xmlreader.c: document all functions returning xmlChar * that they
  need to free the result, and some space/tabs cleanups

8 years ago574393 – utf-8 filename magic for compressed files
Hans Breuer [Tue, 11 Aug 2009 15:51:22 +0000 (17:51 +0200)]
574393 – utf-8 filename magic for compressed files

* xmlIO.c: windows specific magic to have UTF-8 file name work with
  compressed files too.

8 years agoFix a couple of problems in the parser
Daniel Veillard [Mon, 10 Aug 2009 14:49:30 +0000 (16:49 +0200)]
Fix a couple of problems in the parser

* parser.c: a couple of nasty bugs CVE-2009-2414 and CVE-2009-2416

8 years ago545579 doesn't compile without schema support
Daniel Veillard [Mon, 10 Aug 2009 13:14:01 +0000 (15:14 +0200)]
545579 doesn't compile without schema support

* testapi.c: fix to get gen_nb_void_ptr_ptr() generated unconditionally

8 years agoxmllint use xmlGetNodePath when not compiled in
Daniel Veillard [Mon, 10 Aug 2009 12:43:18 +0000 (14:43 +0200)]
xmllint use xmlGetNodePath when not compiled in

* xmllint.c: clean up usages of xmlGetNodePath() to make sure it was
  compiled in. Also clear some space issues, solves #545581

8 years agoTry to avoid __imp__xmlFree link trouble on msys
Daniel Veillard [Mon, 10 Aug 2009 08:08:41 +0000 (10:08 +0200)]
Try to avoid __imp__xmlFree link trouble on msys

* include/libxml/xmlexports.h: when compiling with mingw/MSYS or linking
  to an precompiled library this _imp__xmlFree missing at runtime is a
  common problem. Igor and various people faced it and this seems the
  minimal fix for it, should resolve 590302 and 561340

8 years agoAllow to select the threading system on Windows
LRN [Fri, 7 Aug 2009 19:47:25 +0000 (21:47 +0200)]
Allow to select the threading system on Windows

* configure.in: changes to enable either pthreads or win32-threads

8 years ago585505 – Document ids and refs populated by XSD
Wayne Jensen [Fri, 7 Aug 2009 19:27:44 +0000 (21:27 +0200)]
585505 – Document ids and refs populated by XSD

* xmlschemas.c: simple patch allowing document ids and refs to be
  asserted when XSD validation is done.

8 years ago582906 XSD validating multiple imports of the same schema
Jason Childs [Fri, 7 Aug 2009 18:29:33 +0000 (20:29 +0200)]
582906 XSD validating multiple imports of the same schema

* xmlschemas.c: When validating a schema that includes the same file
  that has no targetNamespace defined an internal erro was thrown,
  depending on the orig namespace that should be allowed though
* test/schemas/582906-* result/schemas/582906-*: 2 tests case, one
  where this is allowed, and one where this is forbidden

8 years agoBug 582887 – problems validating complex schemas
Jason Childs [Fri, 7 Aug 2009 17:01:32 +0000 (19:01 +0200)]
Bug 582887 – problems validating complex schemas

* xmlschemas.c: fixes the problem faced when importing the same schemas
  multiple times but from different places which is allowed
* test/schemas/582887* result/schemas/582887*: adding the specific test
  to the regressions

8 years agoBug 579729 – fix XSD schemas parsing crash
Miroslav Bajtos [Fri, 7 Aug 2009 15:22:12 +0000 (17:22 +0200)]
Bug 579729 – fix XSD schemas parsing crash

* xmlschemas.c: a typo in XSD schema validation, where inherited
  bfminlen rewrote blength and caused SIGSEGV

8 years ago576368 – htmlChunkParser with special attributes
Jiri Netolicky [Fri, 7 Aug 2009 15:05:36 +0000 (17:05 +0200)]
576368 – htmlChunkParser with special attributes

* HTMLparser.c: htmlChunkParsing failed when the chunk ends inside
  element after some attribute which  has a '>' char in its value.

8 years agoBug 565747 – relax anyURI data character checking
Vincent Lefevre [Fri, 7 Aug 2009 14:42:24 +0000 (16:42 +0200)]
Bug 565747 – relax anyURI data character checking

* xmlschemastypes.c: anyURI values that contain an apostrophe or a
  space character or any non-ascii char were rejected, this is opposed
  to XSD-1.0 datatype rules

8 years agoFix Solaris binary links, cleanups
Daniel Veillard [Fri, 7 Aug 2009 14:27:15 +0000 (16:27 +0200)]
Fix Solaris binary links, cleanups

* doc/*.html doc/site.xsl doc/xml.html: Dagobert Michelsen pointed out
  that binaries build for Solaris now live in OpenCSW

8 years agoBug 571059 – MSVC doesn't work with the bakefile
Intron [Fri, 7 Aug 2009 14:19:15 +0000 (16:19 +0200)]
Bug 571059 – MSVC doesn't work with the bakefile

* bakefile/libxml2.bkl: MSVC 2008 Ex will report that it cannot
  find "config.h", should be fixed with patch

8 years agoPreserve attributes of include start on tree copy
Petr Pajas [Thu, 30 Jul 2009 15:47:32 +0000 (17:47 +0200)]
Preserve attributes of include start on tree copy

* tree.c: copy attributes and namespaces for that kind of node

8 years agoSkip silently unrecognized XPointer schemes
Jakub Wilk [Wed, 29 Jul 2009 10:24:11 +0000 (12:24 +0200)]
Skip silently unrecognized XPointer schemes

* xpointer.c: unrecognized XPointers should be skipped instead of
  aborting the full XPointer evaluation

8 years agoFix leak on SAX1, xmllint --sax1 option and debug
Daniel Veillard [Wed, 29 Jul 2009 09:34:50 +0000 (11:34 +0200)]
Fix leak on SAX1, xmllint --sax1 option and debug

* SAX2.c: don't leak in xmlCheckDefaultedAttributes for standalone
  checking
* xmllint.c: fix xmllint --sax1 to actually use XML_PARSE_SAX1
* debugXML.c: don't raise an error if markup wasn't allocated from
  dictionary if document was parsed with option disabling it