Filing in MailNews: Mail Database for lack of a better component for mork bugs. Various mork functions, such as: morkTableRowCursor::NextRow morkTableRowCursor::PrevRow morkTableRowCursor::MakeUniqueCursor morkTable::GetMetaRow morkTable::GetTableRowCursor morkTable::PosToRow morkTable::NewRow morkFactory::CreateNewFile morkFactory::MakeHeap morkFactory::OpenFilePort morkFactory::ThumbToOpenPort morkFactory::OpenFileStore morkFactory::ThumbToOpenStore morkFactory::CreateNewFileStore and probably others end with code like: if ( acqStore ) *acqStore = outStore; All of these functions will silently leak if the out parameter is null. I think these functions should definitely assert if the out parameter is null so they can't lead to silent leaks. However, I also don't see any reason to null-check out parameters (other than for DEBUG-only assertions) when getting the out parameter is the sole purpose of calling the function -- so I think the better solution to this bug is to remove the null checks rather than adding |else outStore->Release();| after each one.
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.