COMMON: Fix calling Span::getStringAt with non-zero index

This commit is contained in:
Colin Snover 2017-02-08 11:49:25 -06:00
parent 3aa660f4c7
commit f1d9955540
2 changed files with 4 additions and 2 deletions

View file

@ -496,6 +496,8 @@ public:
TS_ASSERT(span.getStringAt(0) == data);
TS_ASSERT(span.getStringAt(0, 2) == "he");
TS_ASSERT(span.getStringAt(2) == "llo");
TS_ASSERT(span.getStringAt(2, 3) == "llo");
span[3] = '\0';
TS_ASSERT(span.getStringAt(0) == "hel");
}