Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sgmlreaderdll/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:

[assembly: AssemblyVersion("1.8.12")]
[assembly: AssemblyFileVersion("1.8.12")]
[assembly: AssemblyVersion("1.8.12.1")]
[assembly: AssemblyFileVersion("1.8.12.1")]

//
// In order to sign your assembly you must specify a key to use. Refer to the
Expand Down
10 changes: 8 additions & 2 deletions sgmlreaderdll/SgmlReader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,12 @@ private void LazyLoadDtd(Uri baseUri)
}
}

// If DocType was specified explicitly, trust it.
if (this.m_dtd == null && this.m_ignoreDtd)
{
this.m_isHtml = StringUtilities.EqualsIgnoreCase(this.m_docType, "html");
}

if (this.m_dtd != null && this.m_dtd.Name != null)
{
switch(this.CaseFolding)
Expand Down Expand Up @@ -1417,9 +1423,9 @@ private void OpenInput()
if (this.m_current.ResolvedUri != null)
this.m_baseUri = this.m_current.ResolvedUri;

if (this.m_current.IsHtml && this.m_dtd == null)
if (this.m_current.IsHtml && this.m_dtd == null
&& !StringUtilities.EqualsIgnoreCase(this.m_docType, "HTML")) // No need to reload DTD in case m_docType == "HTML"
{
this.m_docType = "HTML";
LazyLoadDtd(this.m_baseUri);
}
}
Expand Down