Modify

Ticket #5259 (closed Bugs: invalid)

Opened 3 years ago

Last modified 2 months ago

embedded nulls not processed parsed correctly from xml

Reported by: Shawn Tsai <sstsai@…> Owned by: cornedbee
Milestone: To Be Determined Component: property_tree
Version: Boost 1.46.0 Severity: Problem
Keywords: Cc:

Description

Embedded null in any value field of an xml file will result in a truncated string in the property_tree.

Attachments

test.zip Download (1.0 KB) - added by Shawn Tsai <sstsai@…> 3 years ago.
a test file along with a test function and a patch file

Change History

Changed 3 years ago by Shawn Tsai <sstsai@…>

a test file along with a test function and a patch file

comment:1 Changed 3 years ago by cornedbee

(In [72001]) Allow nuls in PTree XML. See bug 5259.

comment:2 Changed 2 years ago by cornedbee

  • Status changed from new to closed
  • Resolution set to fixed

(In [76447]) Merge [72000],[72001],[72003], [74691], [75587], [75589], [75590], and [75593] from trunk. Fixes bug 4840. Fixes bug 5259. Fixes bug 5281, I think. Fixes bug 5944. Fixes bug 5757. Fixes bug 5710. Fixes bug 5307, I think.

comment:3 Changed 19 months ago by arkadiy_s@…

It is supposed that Ptree have constructor from std::basic_string (see property_tree/detail/xml_parser_read_rapidxml.hpp line 77), but it actually doesn't. We don't use boost::property_tree::ptree, we use our implementation of pree. BTW user can use boost::property_tree::basic_ptree from different types.

Please revert this fix!

comment:4 Changed 19 months ago by anonymous

  • Status changed from closed to reopened
  • Resolution fixed deleted

comment:5 Changed 2 months ago by cornedbee

  • Status changed from reopened to closed
  • Resolution set to invalid

All the serializers only work with PTrees whose data type is std::basic_string. Anything different is just an accident.

This will be clarified with the doc update, and possibly changed eventually. But I have to figure out a good way of doing so.

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.