Commit Graph
45 Commits
Author SHA1 Message Date
Rodrigo Kumpera 8752d92528 Kill MOONLIGHT from System.Xml. 2013-02-11 16:03:40 -05:00
Geoff Norton 98f4834a34 Fix the mobile build 2011-03-14 16:11:42 -04:00
Atsushi Eno 208fdd9a47 Enable DTD attdecl processing in mobile profile. 2011-03-15 00:44:43 +09:00
Atsushi Eno 61ec829ea9 2010-04-21 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs, DTDReader.cs : 0xFFFF was treated as if it were
	  0x10000. (It is invalid and should be rejected by decent
	  XmlReaders usage though.) Fixed bug #594628.


svn path=/trunk/mcs/; revision=155853
2010-04-21 08:19:39 +00:00
Atsushi Eno fea31fd77d 2009-03-16 Atsushi Enomoto <[email protected]>
* DTDRreader.cs : read up all DTD stream so that we don't have to
	  see bugs like #469317 many times.


svn path=/trunk/mcs/; revision=129465
2009-03-16 16:14:31 +00:00
Marek Safar 95a6e77b85 Warnings cleanup
svn path=/trunk/mcs/; revision=111839
2008-08-28 16:53:31 +00:00
Jb Evain 65778b3d58 use sl compatible hack
svn path=/trunk/mcs/; revision=109657
2008-08-05 10:11:25 +00:00
Atsushi Eno 7fca944c2b 2007-07-04 Atsushi Enomoto <[email protected]>
* SubtreeXmlReader.cs XmlFilterReader.cs :
	  exclude xsd stuff from NET_2_1 profile.

	* DTDAutomata.cs DTDObjectModel.cs DTDReader.cs
	  DTDValidatingReader2.cs XmlException.cs XmlReader.cs
	  XmlReaderSettings.cs XmlWriter.cs :
	  Make System.Xml.Core.dll build easier, using NET_2_1.

	  DTD support is simply cut at this stage (as it largely depends on
	  sys.xml.schema stuff).


svn path=/trunk/mcs/; revision=81332
2007-07-04 13:19:57 +00:00
Atsushi Eno bf12cc0a6d 2006-10-27 Atsushi Enomoto <[email protected]>
* DTDReader.cs : some parameter entity expansions were not done.
	  Fixed bug #79683.

	* 79683.dtd : added for bug #79683.

	* XmlTextReaderTests.cs : added bug #79683 case.

	* Makefile : added 79683.dtd to dist file.


svn path=/trunk/mcs/; revision=67025
2006-10-27 13:14:25 +00:00
Atsushi Eno f97f300d60 2006-08-17 Atsushi Enomoto <[email protected]>
* XmlEntity.cs, XmlEntityReference.cs, XmlNode.cs :
	  create entity content only when its children is being accessed.
	  It results differently when there is no actual reference in the
	  document - an invalid entity value (when it is used to create
	  child nodes) is ignored unless a code tries to access the Value
	  of an XmlEntity. Fixed bug #79091
	* DTDReader.cs : the fix above uncovered another bug (ibm66n03.xml).
	  Check illegal reference name in literal entity value.


svn path=/trunk/mcs/; revision=63900
2006-08-17 11:55:56 +00:00
Atsushi Eno c8f61053ec 2006-08-17 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs, XmlTextReader2.cs, DTDReader.cs :
	  (ResolveExternalEntityReplacementText) need to skip text
	  declaration in external entities. To make it possible internalize
	  SkipTextDeclaration() in XmlTextReader(2). Fixed bug #79090.


svn path=/trunk/mcs/; revision=63890
2006-08-17 08:19:29 +00:00
Atsushi Eno e129534ca8 2005-08-16 Atsushi Enomoto <[email protected]>
* DTDReader.cs : no need to skip text declaration for such entity
	  declaration that has literal entity. It should not expand entities
	  inside ResolveExternalEntityReplacementText().
	  Finally fixed bug #51495.


svn path=/trunk/mcs/; revision=48444
2005-08-16 18:47:53 +00:00
Atsushi Eno 718c8cb031 2005-08-16 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs, XmlTextReader2.cs : added internal .ctor() to
	  receive both TextReader, XmlNodeType and BaseURI for entity
	  resolution (though it would be removed later).
	* XmlParserInput.cs : Now to handle nested PE insertion and correct
	  BaseURI, it internally holds a stack of "input source".
	* DTDObjectModel.cs,
	  DTDReader.cs :
	  Required fixes for XmlParserInput.
	  Handle BaseURI as expected. Added ActualUri for resolved actual
	  source URI (to resolve nested entities). Pass ActualUri to internal
	  XmlTextReader.ctor() in ResolveExternalEntityReplacementText()
	  (well, yes I remember, it is problematic.)

	  Incorrect Base URI handling bug (part of #51495) is fixed.


svn path=/trunk/mcs/; revision=48443
2005-08-16 18:23:16 +00:00
Atsushi Eno f6ccddf3c3 2005-08-16 Atsushi Enomoto <[email protected]>
* DTDReader.cs, XmlParserInput.cs :
	  let's fix #51495. First of all, refactoring.


svn path=/trunk/mcs/; revision=48438
2005-08-16 16:30:00 +00:00
Andrew Skiba 8e800a1d51 Fixes valid-sa-086 test from W3C xmlconf suite
svn path=/trunk/mcs/; revision=46552
2005-06-27 12:19:24 +00:00
Atsushi Eno 90cd8391f9 2005-05-31 Atsushi Enomoto <[email protected]>
* DTDReader.cs :
	  make sure to close parser input before parser stack pop.
	* DTDValidatingReader.cs : ditto.
	* DTDObjectModel.cs : Fixed another incorrect null BaseURI check.

	* XmlValidatingReaderTests.cs : let's test external DTD as well.


svn path=/trunk/mcs/; revision=45262
2005-05-31 13:37:32 +00:00
Atsushi Eno b0c7f07f28 2005-03-09 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs, XmlParserInput.cs, DTDReader.cs: fix UCM-4
	  surrogate calculations. This fixes bug #73513. Patch by
	  Andrew Skiba.

	* XmlTextReaderTests.cs : added SurrogatePair() based on bug #73513.



svn path=/trunk/mcs/; revision=41610
2005-03-09 18:21:10 +00:00
Atsushi Eno ea5f087e84 2004-12-26 Atsushi Enomoto <[email protected]>
* XmlSchema.cs : XmlResolver.ResolveUri() may return null.

	* XmlParserContext.cs : all the string properties must not be set as
	  null. Thanks to Joshua.
	* XmlTextReader.cs,
	  DTDObjectModel.cs,
	  DTDReader.cs : XmlResolver.ResolveUri() may return null.

	* XsdValidatingReader.cs : XmlResolver.ResolveUri() may return null.

	* XslFunction.cs,
	  Compiler.cs : XmlResolver.ResolveUri() may return null.



svn path=/trunk/mcs/; revision=38084
2004-12-26 16:26:30 +00:00
Atsushi Eno c074d29c67 2004-11-30 Atsushi Enomoto <[email protected]>
* DTDReader.cs : Consideration on parameter entity was missing for 
	  attribute default value. Fixed bug #70008.



svn path=/trunk/mcs/; revision=36816
2004-11-30 06:19:52 +00:00
Atsushi Eno 16dd4c5974 2004-11-26 Atsushi Enomoto <[email protected]>
* XmlReader.cs : not fixage, just explicitly formatted code a bit.
	* XmlTextReader.cs,
	  XmlEntity.cs,
	  XmlAttributeCollection.cs,
	  XmlTextWriter.cs,
	  XmlElement.cs,
	  XmlNode.cs,
	  DTDObjectModel.cs,
	  XmlParserInput.cs,
	  DTDReader.cs,
	  XmlDocument.cs : warning removal.



svn path=/trunk/mcs/; revision=36587
2004-11-26 02:51:06 +00:00
Atsushi Eno f6a6ca4b93 2004-11-08 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs,
	  DTDReader.cs,
	  XmlReader.cs,
	  XmlTextReader.cs,
	  XmlException.cs :

	  Added support for 2.0 XmlException.SourceUri property. Improved
	  exception handling to contain BaseURI everywhere in the parser.

svn path=/trunk/mcs/; revision=35820
2004-11-08 09:18:29 +00:00
Atsushi Eno ff1ec3a518 2004-10-29 Atsushi Enomoto <[email protected]>
* DTDReader.cs, DTDValidatingReader.cs, XmlTextReader.cs :
	  When XmlTextReader is created with NodeType Element or Attribute,
	  skip possible text declaration (that might be used for resolving
	  entities) that specifies text encoding. With this fix, bug #61274
	  must be regarded as fixed.

svn path=/trunk/mcs/; revision=35428
2004-10-29 04:48:04 +00:00
Atsushi Eno ac50fa24b0 2004-08-10 Atsushi Enomoto <[email protected]>
* DTDReader.cs : Replacing XmlSchemaDatatype .FromName(string) with
	  .FromName(string, string) [going to remove former one; it is not
	  good to support xdt:blah datatypes].

svn path=/trunk/mcs/; revision=32141
2004-08-10 13:52:25 +00:00
Duncan Mak 8fa6e766dd Add MIT license to System.XML.DLL
svn path=/trunk/mcs/; revision=30055
2004-06-21 18:07:31 +00:00
Atsushi Eno 47029604e8 2004-06-18 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs, DTDReader.cs, XmlConvert.cs, XmlDocument.cs,
	  XmlException.cs, XmlParserInput.cs, XmlTextReader.cs,
	  XmlTextWriter.cs : Globalization.
	* XmlNode.cs : Fixed error message that confused node type.

svn path=/trunk/mcs/; revision=29825
2004-06-18 01:22:07 +00:00
Atsushi Eno 12c0df7558 2004-05-24 Atsushi Enomoto <[email protected]>
* DTDReader.cs : When sequential PE references exist, the reader only
	  expands the first one and in some cases the parser complaints the
	  content (such like expecting name character but found '%').
	  This fixes bug #58818.

svn path=/trunk/mcs/; revision=27941
2004-05-24 07:39:49 +00:00
Atsushi Eno 4190429496 2004-05-12 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs,
	  DTDReader.cs,
	  XmlDocument.cs,
	  XmlInputStream.cs,
	  XmlParserInput.cs,
	  XmlTextReader.cs,
	  XmlUrlResolver.cs : removed reference to Mono.Xml.
	  Made Mono.Xml.* classes internal.
	* XmlDocument.cs : output xml declaration for TextWriter output in Save()
	* XmlElement.cs : Name character check should be done in .ctor().
	* XmlNamespaceManager.cs : Removed dangerous internal .ctor()

svn path=/trunk/mcs/; revision=27149
2004-05-12 09:11:19 +00:00
Atsushi Eno a5e122f6a2 2004-04-24 Atsushi Enomoto <[email protected]>
* DTDReader.cs, XmlConvert.cs, XmlDeclaration.cs, XmlImplementation.cs,
	  XmlNode.cs : Culture independency fix.

svn path=/trunk/mcs/; revision=25929
2004-04-24 10:15:09 +00:00
Atsushi Eno 865fccec0d 2004-04-06 Atsushi Enomoto <[email protected]>
* DTDReader.cs : In ProcessDTDSubset(), 1)error message was
	  generated with incorrect stream character, 2)entity nest check
	  should not depend on line info which might not be supplied, 3)
	  empty PE should be skipped.
	* XmlParserInput.cs : use index for StringBuilder instead of calling
	  Remove() many times. This highly optimizes DTD parser.

	* XmlAttribute.cs : removed commented code.
	* XmlEntity.cs : removed unused field.

svn path=/trunk/mcs/; revision=25070
2004-04-06 01:42:14 +00:00
Atsushi Eno b123e6f7c5 2004-04-05 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs : (DTDAttributeDefinition) create ArrayList
	  only when they are required.
	* DTDReader.cs,
	  XmlParserInput.cs : raw tag string now don't have to be kept, while
	  it cost so much. Removed unused code. 20% to 30% memory got saved.
	* XmlNotation.cs : removed unused code.
	* XmlTextReader.cs : Removed unused code. ReadString() now uses
	  XmlReader's internal method. Fixed BaseURI to be conformant with
	  W3C XML InfoSet and (subsequently) xml:base specification (i.e.
	  reflect xml:base attribute correctly).

svn path=/trunk/mcs/; revision=25026
2004-04-05 09:32:48 +00:00
Atsushi Eno dcdf2745d6 2004-03-27 Atsushi Enomoto <[email protected]>
* DTDReader.cs : In some places sequential parameter entity was
	  incorrectly skipped (and caused invalid result).

svn path=/trunk/mcs/; revision=24661
2004-03-27 22:00:44 +00:00
Atsushi Eno 822f455b93 2004-02-16 Atsushi Enomoto <[email protected]>
* DTDAutomata.cs,
	  DTDObjectModel.cs,
	  DTDReader.cs,
	  DTDValidatingReader.cs : made classes internal.
	* XmlDocument.cs : removed extra FIXMEs.
	* XmlNamedNodeMap.cs,
	  XmlResolver.cs,
	  XmlUrlResolver.cs :
	  Fixed incorrect method signature.

svn path=/trunk/mcs/; revision=23142
2004-02-16 19:04:50 +00:00
Atsushi Eno 27496c3d66 2004-02-13 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs, DTDReader.cs, DTDValidatingReader.cs :
	  say goodbye to sys.collections.specialized.
	  (replaced the classes in that namespace with ArrayList or Hashtable)

svn path=/trunk/mcs/; revision=23073
2004-02-13 20:08:50 +00:00
Atsushi Eno 8256002451 2004-02-08 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs : Limit external entity reference from DTD by 256.
	  foreach elimination.  DTDParameterEntityDeclaration should set Root.
	  Compute attribute default value without raising an error.
	  (for non-error reporting reader)
	* DTDReader.cs : Fixes for the above fixes. foreach elimination.
	* DTDValidatingReader.cs, NameTable.cs, XmlAttribute.cs,
	  XmlAttributeCollection.cs, XmlChar.cs, XmlConstruct.cs,
	  XmlDocumentFragment.cs, XmlDocumentNavigator.cs, XmlElement.cs,
	  XmlEntityReference.cs, XmlNamedNodeMap.cs, XmlNode.cs,
	  XmlText.cs : foreach elimination.
	* XmlDocument.cs, XmlSignificantWhitespace.cs, XmlWhitespace.cs :
	  foreach elimination. Removed unnecesary methods.
	* XmlTextReader.cs : code format refactory. Optimized some methods.
	  foreach elimination. Replaced Stack with string array.
	  Replaced StringBuilder with char array. Removed unnecessary methods.

svn path=/trunk/mcs/; revision=22891
2004-02-08 20:27:04 +00:00
Atsushi Eno a540306d7f 2004-02-03 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs, DTDReader.cs : fixity fix ;)

svn path=/trunk/mcs/; revision=22744
2004-02-03 15:28:44 +00:00
Atsushi Eno 80b1ad3644 2004-02-03 Atsushi Enomoto <[email protected]>
* ChangeLog : Fixed incorrect description that should be written for
	  DTDValidatingReader.cs but written for DTDReader.cs.
	* DTDValidatingReader.cs : Fixes described in the last DTDReader fix.

	* XmlChar.cs,
	  XmlConstructs.cs : Made XmlChar and XmlConstructs equivalent and
	  replaced XmlChar with XmlConstruts, renaming "XmlChar" to
	  "XmlCharCompact" and "XmlConstructs" to "XmlChar".
	  (XmlChar will be used for compact framework.)
	* DTDReader.cs, XmlParserInput.cs, XmlTextReader.cs :
	  XmlChar related changes.  Support for surrogate pair.
	  It cannot use TextReader's peek anymore (for surrogate pair).
	  Character range check for PI value, attribute value, text
	* XmlTextWriter.cs : Change openElements from Stack to ArrayList.
	  (It calls ToArray() every time.)

svn path=/trunk/mcs/; revision=22741
2004-02-03 15:04:03 +00:00
Atsushi Eno 949ccf26e7 2004-02-03 Atsushi Enomoto <[email protected]>
* XmlChar.cs : now GetPredefinedEntity() returns int and -1 for not
	  predefined entity names.
	* DTDObjectModel.cs : DTDxxxCollection now derives from
	  - DTDCollectionBase that derives from DictionaryBase.
	  - "Literal value" and "replacement text" are handled differently.
	  - Throw XmlException when external entity could not be resolved.
	  - Return ReplacementText for EntityValue.
	* DTDReader.cs :
	  - Support IXmlLineInfo.
	  - Fixed IGNORE section handling to be more strict.
	  - Compute replacement text on reading entity declarations.
	  - Don't expand char references before getting literal entity value.
	  - Check not allowed parameter entity inside internal subset.
	  - Added ValidateWhitespaceNode() to check whitespace's Validity
	    Constraints on external elementdecl and standalone document.
	  - When invalid data against its datatype was found, don't throw
	    parse error.
	  - Other code refactory.
	* XmlTextReader.cs :
	  - Check for invalid Text pattern "]]>" should not depend on line
	    info since it might not be supported.
	  - Check referenced character's validity (WFC).

svn path=/trunk/mcs/; revision=22730
2004-02-03 08:07:35 +00:00
Atsushi Eno fa84bb251d 2004-01-28 Atsushi Enomoto <[email protected]>
* DTDReader.cs : Added Normalization.  Parameter Entity declaration
	  should block invalid characters. (GEDecl should be fixed as well.)
	* XmlConstruct.cs : Should allow surrogate chars.
	* XmlNotation.cs : When prefix is empty (i.e. almost all cases)
	  Name should not add ':'. Patch by Boris Kirzner.
	* XmlTextReader.cs : Modified private ReadCharacterReference() to
	  return the character (or -1 when should not return anything).
	  Now Text character reference are checked their character range.
	  Set DTDReader.Normalization as well as the reader itself.

svn path=/trunk/mcs/; revision=22580
2004-01-28 16:27:49 +00:00
Atsushi Eno 2ea27f0a02 2004-01-28 Atsushi Enomoto <[email protected]>
* DTDReader.cs : Make sure that parameter entities are not allowed
	  inside internal subset unless it appears as a markupdecl.
	* DTDValidatingReader.cs : ENTITY or ENTITIES type attributes must have
	  a value that indicates *unparsed* entity (i.e. NDATA required).

svn path=/trunk/mcs/; revision=22567
2004-01-28 07:21:05 +00:00
Atsushi Eno 5dc2265c13 2004-01-26 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs :
	  - DTDNode's BaseURI should not always refer to that of DTD's.
	  - Use absolute URI's .ToString() instead of AbsolutePath.
	* DTDReader.cs : Throw XmlException for illegal character references.
	* DTDValidatingReader.cs :
	  - Share XmlResolver when the actual reader is XmlTextReader.
	    (MS's XmlValidatingReader and XmlTextReader do this.)
	  - Added its own EntityHandling property.
	* XmlValidatingReader.cs : Share XmlResolver with XmlTextReader.
	* XmlReader.cs,
	  XmlTextReader.cs : Added new NET_1_2 members.
	* XmlElement.cs : Removed extra lines (caused by XmlTextWriter bugs).
	* XmlEntityReference.cs : Forgot to add, the real fix by Boris.

svn path=/trunk/mcs/; revision=22509
2004-01-26 18:25:39 +00:00
Atsushi Eno 65b863c896 2004-01-07 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs, DTDReader.cs, XmlSecureResolver.cs :
	  avoiding obvious exception.
	* DTDReader.cs, XmlTextReader.cs : Some optimization.
	  Avoided extraneous PeekChar() and reduced name string creation.

svn path=/trunk/mcs/; revision=21797
2004-01-07 09:05:23 +00:00
Atsushi Eno e22ed2eb99 2003-12-16 Atsushi Enomoto <[email protected]>
* DTDValidatingReader.cs : Validity check and entity expansion were
	  incorrectly mixed.
	* DTDObjectModel.cs, DTDReader.cs, XmlInputStream.cs :
	  Going to remove XmlInputStream. XmlStreamReader might be replacable.

svn path=/trunk/mcs/; revision=21242
2003-12-16 15:38:15 +00:00
Atsushi Eno 5f6674b5da 2003-10-25 Atsushi Enomoto <[email protected]>
* DTDReader.cs, DTDValidatingReader.cs, XmlInputStream.cs,
	  XmlTextReader.cs : More cleanup.
	* XmlDocument.cs : Removed CheckName(). Code cleanup.
	* XmlElement.cs : .ctor() now adds default attributes (if required).
	* XmlAttribute.cs, XmlElement.cs, XmlEntity.cs, XmlEntityReference.cs,
	  XmlNotation.cs : Now uses OwnerDocument's NameTable.

svn path=/trunk/mcs/; revision=19404
2003-10-26 03:39:03 +00:00
Atsushi Eno 4cb580369a 2003-10-25 Atsushi Enomoto <[email protected]>
* DTDReader.cs,
	  XmlConstructs.cs,
	  XmlTextReader.cs,
	  XmlWriter.cs : Fixed incorrect access modifier.
	* XmlTextWriter.cs : Imported state variable from XmlWriter.
	* DTDValidatingReader.cs : Removed extraneous MonoTODO.
	* XmlConvert.cs : Implemented ToTimeSpan().
	  Modified ToDateTime() to reuse the same array.

svn path=/trunk/mcs/; revision=19373
2003-10-25 09:36:42 +00:00
Atsushi Eno a02a5b1d9c 2003-10-09 Atsushi Enomoto <[email protected]>
* Added DTDReader.cs. It is almost importation of XmlTextReader.
	* DTDObjectModel.cs :
	  - More .NET-ism. Properties took place of fields.
	  - Imported PE set from XmlTextReader. Added location info.
	  - Added DTDEntityBase common to PE and GE.
	  - More correct text declaration handling with new XmlTextReader.
	* DTDValidatingReader.cs :
	  - Now uses entity resolving XmlTextReader to validate attributes
	    correctly. Implemented standalone
	  - Standalone and default related validity constraints check.
	* XmlImplementation.cs: Implemented HasFeature().
	* XmlNode.cs : Implemented Supports().
	* XmlNodeReader.cs : Modified to use XmlTextReader.SkipTextDeclaration()
	* XmlParserInput.cs : Removed extraneous members.
	* XmlTextReader.cs :
	  - All DTD related functionality now goes to DTDReader.cs
	  - It became old simple TextReader input style.
	  - Implemented GetRemainder().
	  - Implemented ReadBase64(), ReadBinHex() and ReadChars(), using
	    additional new private method ReadUntilEndTag().
	  - Removed incomplete MaybeTextDecl and added SkipTextDeclaration().
	    ReadXmlDeclaration() now became simple.
	  - More strict entity reference check at SetEntityReferenceProperty()
	  - Removed extraneous members.
	* XmlWriter.cs : WriteNode(XmlNodeType.None) does not raise error.

svn path=/trunk/mcs/; revision=18812
2003-10-09 19:13:16 +00:00