diff options
author | 2016-11-21 07:48:43 +1100 | |
---|---|---|
committer | 2016-11-21 07:48:43 +1100 | |
commit | 0757bf61fd379753ae70eb0efa7742369e943ba7 (patch) | |
tree | 60573348f40facd1ece3ca6043c4bb38438b4031 /src/lib/util/xmlfile.cpp | |
parent | c7352f5684c6dc3a4f5db3e3514e61646c061336 (diff) |
Work around buggy standard libraries (nw)
Diffstat (limited to 'src/lib/util/xmlfile.cpp')
-rw-r--r-- | src/lib/util/xmlfile.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/util/xmlfile.cpp b/src/lib/util/xmlfile.cpp index 18d49926188..458f3028e76 100644 --- a/src/lib/util/xmlfile.cpp +++ b/src/lib/util/xmlfile.cpp @@ -250,13 +250,13 @@ void xml_data_node::append_value(char const *value, int length) void xml_data_node::trim_whitespace() { /* first strip leading spaces */ - std::string::const_iterator start = m_value.begin(); + std::string::iterator start = m_value.begin(); while ((m_value.end() != start) && std::isspace(uint8_t(*start))) ++start; m_value.replace(m_value.begin(), start, 0U, '\0'); /* then strip trailing spaces */ - std::string::const_iterator end = m_value.end(); + std::string::iterator end = m_value.end(); while ((m_value.begin() != end) && std::isspace(uint8_t(*std::prev(end)))) --end; m_value.replace(end, m_value.end(), 0U, '\0'); |