Fixed read of wrong address

This commit is contained in:
llsth 2015-04-13 00:04:31 +02:00
parent 88664a91de
commit 8bec52a8ee
1 changed files with 4 additions and 0 deletions

View File

@ -217,6 +217,10 @@ void CharBuffer::Append(const char* source)
bool CharBuffer::RemoveTrailing(const char c)
{
if (ptr == buf) {
return false;
}
if (*(ptr - 1) == c) {
ptr--;
return true;