|
Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.ide digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript electronics |
digitalmars.D.bugs - [Issue 2063] New: std.xml access violation for nested, closed tags
http://d.puremagic.com/issues/show_bug.cgi?id=2063 Summary: std.xml access violation for nested, closed tags Product: D Version: 2.013 Platform: PC OS/Version: Windows Status: NEW Severity: major Priority: P2 Component: Phobos AssignedTo: bugzilla digitalmars.com ReportedBy: gaboonviper gmx.net If a closed <node/> is written inside another node, an access violation occurs in the constructor of the xml document document. works: <?xml version="1.0"?><tag/> doesn't work: <?xml version="1.0"?><something><tag/></something> this was tested using the following setup: import std.stdio; import std.file; import std.xml; void main{ string s = cast(string)std.file.read("widget2.xml"); check(s); auto doc = new Document(s); writefln(doc); } Cheers, Boyd -- May 02 2008
http://d.puremagic.com/issues/show_bug.cgi?id=2063 ------- Comment #1 from gide nwawudu.com 2008-05-02 10:52 ------- Malformed XML also access violates. E.g. ---- <?xml version="1.0"?><widget> -- May 02 2008
OK, thanks. Will look into that one. Janice On 02/05/2008, d-bugmail puremagic.com <d-bugmail puremagic.com> wrote:http://d.puremagic.com/issues/show_bug.cgi?id=2063 Summary: std.xml access violation for nested, closed tags Product: D Version: 2.013 Platform: PC OS/Version: Windows Status: NEW Severity: major Priority: P2 Component: Phobos AssignedTo: bugzilla digitalmars.com ReportedBy: gaboonviper gmx.net If a closed <node/> is written inside another node, an access violation occurs in the constructor of the xml document document. works: <?xml version="1.0"?><tag/> doesn't work: <?xml version="1.0"?><something><tag/></something> this was tested using the following setup: import std.stdio; import std.file; import std.xml; void main{ string s = cast(string)std.file.read("widget2.xml"); check(s); auto doc = new Document(s); writefln(doc); } Cheers, Boyd -- May 02 2008
OK, thanks. I will definitely investigate that. Question: Is this in debug mode or release mode? If it's in a release build, it's not really a bug in std.xml, because you're not supposed to pass malformed XML to the parsing functions. (You call check() first, to make sure it's well formed). But if it's in a debug build, then it's definitely a bug in my code, because in that case, it should assert somewhere - ideally in an in contract. Janice On 02/05/2008, d-bugmail puremagic.com <d-bugmail puremagic.com> wrote:http://d.puremagic.com/issues/show_bug.cgi?id=2063 ------- Comment #1 from gide nwawudu.com 2008-05-02 10:52 ------- Malformed XML also access violates. E.g. ---- <?xml version="1.0"?><widget> -- May 02 2008
http://d.puremagic.com/issues/show_bug.cgi?id=2063 ------- Comment #4 from gide nwawudu.com 2008-05-03 11:55 -------Question: Is this in debug mode or release mode? May 03 2008
OK, thanks very much. Will fix. Janice On 03/05/2008, d-bugmail puremagic.com <d-bugmail puremagic.com> wrote:http://d.puremagic.com/issues/show_bug.cgi?id=2063 ------- Comment #4 from gide nwawudu.com 2008-05-03 11:55 -------Question: Is this in debug mode or release mode? May 03 2008
http://d.puremagic.com/issues/show_bug.cgi?id=2063 caron800 googlemail.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED -- May 07 2008
|