Activity log for bug #768379

Date Who What changed Old value New value Message
2011-04-21 14:38:35 rexpie@gmail.com bug added bug
2011-04-21 14:39:04 rexpie@gmail.com description pbzip2 ver 1.1.3: pbzip2.cpp: In the producer(int hInfile, int blockSize, queue *fifo) function, there is a piece of code: (line 2482) outBuff * queueElement = new(std::nothrow) outBuff(FileData, inSize, NumBlocks, 0); // make sure memory was allocated properly if (queueElement == NULL) { close(hInfile); handle_error(EF_EXIT, -1, "pbzip2: *ERROR: Could not allocate memory (queueElement)! Aborting...\n"); return -1; } However inprobable, but when the allocation do fail, the fifo->mut mutex is not unlocked when the function returns with an error. This is an analysis finding when we are doing research on finding unmatched lock/unlock statements. We are very grateful for your source code which has been very helpful for our research. Thank you. pbzip2 ver 1.1.3: pbzip2.cpp: In the producer(int hInfile, int blockSize, queue *fifo) function, there is a piece of code: (line 2482) outBuff * queueElement = new(std::nothrow) outBuff(FileData, inSize, NumBlocks, 0); // make sure memory was allocated properly if (queueElement == NULL)                 {                         close(hInfile);                         handle_error(EF_EXIT, -1, "pbzip2: *ERROR: Could not allocate memory (queueElement)! Aborting...\n");                         return -1;                 } However improbable, but when the allocation do fail, the fifo->mut mutex is not unlocked when the function returns with an error. This is an analysis finding when we are doing research on finding unmatched lock/unlock statements. We are very grateful for your source code which has been very helpful for our research. Thank you.
2011-04-21 14:39:39 rexpie@gmail.com description pbzip2 ver 1.1.3: pbzip2.cpp: In the producer(int hInfile, int blockSize, queue *fifo) function, there is a piece of code: (line 2482) outBuff * queueElement = new(std::nothrow) outBuff(FileData, inSize, NumBlocks, 0); // make sure memory was allocated properly if (queueElement == NULL)                 {                         close(hInfile);                         handle_error(EF_EXIT, -1, "pbzip2: *ERROR: Could not allocate memory (queueElement)! Aborting...\n");                         return -1;                 } However improbable, but when the allocation do fail, the fifo->mut mutex is not unlocked when the function returns with an error. This is an analysis finding when we are doing research on finding unmatched lock/unlock statements. We are very grateful for your source code which has been very helpful for our research. Thank you. pbzip2 ver 1.1.3: pbzip2.cpp: In the producer(int hInfile, int blockSize, queue *fifo) function, there is a piece of code: (line 2482) outBuff * queueElement = new(std::nothrow) outBuff(FileData, inSize, NumBlocks, 0); // make sure memory was allocated properly if (queueElement == NULL) {  close(hInfile);  handle_error(EF_EXIT, -1, "pbzip2: *ERROR: Could not allocate memory (queueElement)! Aborting...\n");  return -1; } However improbable, but when the allocation do fail, the fifo->mut mutex is not unlocked when the function returns with an error. This is an analysis finding when we are doing research on finding unmatched lock/unlock statements. We are very grateful for your source code which has been very helpful for our research. Thank you.