forked from Mirrors/privacore-open-source-search-engine
set safebuf::m_buf to null in destructor
This commit is contained in:
@ -79,6 +79,7 @@ SafeBuf::SafeBuf(char *heapBuf, long bufMax, long bytesInUse, bool ownData) {
|
||||
SafeBuf::~SafeBuf() {
|
||||
if(!m_usingStack && m_buf)
|
||||
mfree(m_buf, m_capacity, "SafeBuf");
|
||||
m_buf = NULL;
|
||||
}
|
||||
|
||||
bool SafeBuf::setBuf(char *newBuf, long bufMax, long bytesInUse, bool ownData,
|
||||
|
Reference in New Issue
Block a user