mirror of https://gitlab.com/rnger/amath
Fixed read of wrong address in empty strings
This commit is contained in:
parent
df8205b810
commit
c8f51571cc
|
@ -217,6 +217,10 @@ void CharBuffer::Append(const char* source)
|
|||
|
||||
bool CharBuffer::RemoveTrailing(const char c)
|
||||
{
|
||||
if (ptr == buf) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (*(--ptr) == c) {
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue