diff options
Diffstat (limited to 'diff.cpp')
-rw-r--r-- | diff.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -115,6 +115,10 @@ void Diff::create(const std::string& xml) m_pos0 = tree.get<int>("diff.start"); m_pos1 = tree.get<int>("diff.end"); + + if (m_pos0 > m_pos1) + throw std::runtime_error("Bad range in diff"); + m_data = tree.get<std::string>("diff.data"); } |