Boost logo

Boost :

Subject: [boost] [PropertyTree] i18n Bug in the build-in rapidxml XML parser
From: 卓强 ZHUO Qiang (zhuo.qiang_at_[hidden])
Date: 2010-09-01 11:06:05


Hi All,

I have encounter an bug in Boost.PropertyTree and submit a patch to fix this
bug 3 month ago: https://svn.boost.org/trac/boost/ticket/4340

Below is a brief description:
----------------------------------------------------------
boost::property_tree::read_xml(wistream&, wptree&) throw exception if
tag/value/attribute has a unicode with '\0' inside,

for example, for unicode char L'\u4E00', an exception will be throw because
the parser treat L'\u4E00' as '\0'.

The following test case reproduce the bug:

BOOST_AUTO_TEST_CASE(test_i18n_xml_tag_name) {

 wistringstream in(L"<\u4E00>abc</\u4E00>"); property_tree::wptree pt;
BOOST_REQUIRE_NO_THROW(property_tree::read_xml(in, pt)); BOOST_CHECK(L"abc"
== pt.get<wstring>(L"\u4E00"));

 }
----------------------------------------------------------------

This ticket have been sleeping for 3 month, I'm wondering if someone could
help review it and apply the patch to the trunk or just fix it in another
way.

More generally, what's the boost policy for maintain the existing library,
especially regarding for the bug fix.

Best Regards,
Qiang
http://zhuoqiang.me


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk