1
0
Fork 0

fixed memory leak

This commit is contained in:
Jan Steemann 2013-07-10 17:00:53 +02:00
parent 702c743a3a
commit 7cb90e675e
1 changed files with 4 additions and 0 deletions

View File

@ -530,6 +530,7 @@ void InnerThreadLoop (bool* goToSleep) {
result = TRI_GetGlobalTransactionFigures(stats);
if (result != TRI_ERROR_NO_ERROR) {
TRI_Free(TRI_UNKNOWN_MEM_ZONE, stats);
LOG_TRACE("the index garbage collector inner loop failed due transactions figures being unavailable");
*goToSleep = true;
return;
@ -548,6 +549,7 @@ void InnerThreadLoop (bool* goToSleep) {
// ........................................................................
if (currentNode == NULL) {
TRI_Free(TRI_UNKNOWN_MEM_ZONE, stats);
*goToSleep = true;
return;
}
@ -559,6 +561,7 @@ void InnerThreadLoop (bool* goToSleep) {
if (!TRI_CompareIntegerUInt32 (&(currentNode->_nodeFlag),
INDEX_GC_NODE_NORMAL_FLAG) ) {
TRI_Free(TRI_UNKNOWN_MEM_ZONE, stats);
*goToSleep = true;
return;
}
@ -660,6 +663,7 @@ void InnerThreadLoop (bool* goToSleep) {
} // end of while loop
TRI_Free(TRI_UNKNOWN_MEM_ZONE, stats);
}