Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify dodgy pointer subtraction that caused occasional crashes now
The first calculation was correct, although more complicated than necessary. The second calculation was incorrect - it calculated a *byte* count instead of a character count. This was previously not noticeable, because std::wstring::assign (at least in the specific form that was called here) respected string zero terminators. ST::string doesn't though, causing buffer overruns and crashes sometimes.
- Loading branch information