Closed
Bug 1311
Opened 26 years ago
Closed 26 years ago
Minor memory leak in CNavDTD.cpp
Categories
(Core :: DOM: HTML Parser, defect, P2)
Tracking
()
VERIFIED
FIXED
People
(Reporter: talmx, Assigned: rickg)
Details
There appears to be a minor memory leak in CNavDTD.cpp:
Line 3270:
//EEEEECCCCKKKK!!!
//This code is confusing, so pay attention.
//If you're here, it's because we were in the midst of consuming a start
//tag but ran out of data (not in the stream, but in this *part* of the stream.
//For simplicity, we have to unwind our input. Therefore, we pop and discard
//any new tokens we've cued this round. Later we can get smarter about this.
if(NS_OK!=result) {
while(mTokenDeque.GetSize()>theDequeSize) {
delete mTokenDeque.PopBack();
}
}
mTokenDeque contains pointers to CToken. However, they are stored as
pointers to void. Thus the delete does not call CToken::~Ctoken.
The line should be:
delete (CToken*)mTokenDeque.PopBack();
Status: NEW → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Updated•26 years ago
|
Status: RESOLVED → VERIFIED
Comment 1•26 years ago
|
||
Per rickg (and per a Purify check), this bug is fixed. Thus, marked as verified.
(Tal, if you have an opportunity and the inclination, please feel free to verify
that this bug is fixed to your satisfaction, and re-open it if you have any
lingering concerns. Thank you!)
You need to log in
before you can comment on or make changes to this bug.
Description
•