Ticket #7519: boost.patch

File boost.patch, 654 bytes (added by nicolas.cavallari@…, 10 years ago)

encode \n and \t when writing XML.

  • boost/property_tree/detail/xml_parser_utils.hpp

     
    6767                    case Ch('&'): r += detail::widen<Ch>("&amp;"); break;
    6868                    case Ch('"'): r += detail::widen<Ch>("&quot;"); break;
    6969                    case Ch('\''): r += detail::widen<Ch>("&apos;"); break;
     70                    case Ch('\t'): r += detail::widen<Ch>("&#9;"); break;
     71                    case Ch('\n'): r += detail::widen<Ch>("&#10;"); break;
    7072                    default: r += *it; break;
    7173                }
    7274            }