Closed
Bug 520661
Opened 16 years ago
Closed 16 years ago
nsDeque should handle out-of-memory better
Categories
(Core :: XPCOM, defect, P2)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla1.9.3a1
| Tracking | Status | |
|---|---|---|
| status1.9.2 | --- | beta1-fixed |
| status1.9.1 | --- | .6-fixed |
People
(Reporter: dbaron, Assigned: dbaron)
Details
Attachments
(1 file)
|
3.49 KB,
patch
|
benjamin
:
review+
benjamin
:
approval1.9.2+
dveditz
:
approval1.9.1.6+
|
Details | Diff | Splinter Review |
peterv and I noticed this while debugging cycle collector crashes; given that the cycle collector creates nsDeque objects that require multi-megabyte allocations, this could actually affect users sometimes.
(The cycle collector, at least, handles silent failure to add to a deque just fine, in that the worst side effect would be failure to collect objects.)
I also made it use memcpy rather than copying the pointers in an array.
Attachment #404717 -
Flags: review?(benjamin)
Updated•16 years ago
|
Attachment #404717 -
Flags: review?(benjamin) → review+
| Assignee | ||
Comment 1•16 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Priority: -- → P2
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a1
| Assignee | ||
Comment 2•16 years ago
|
||
Comment on attachment 404717 [details] [diff] [review]
patch
Want to get this in on the chance that it's responsible for some of the cycle collector crashes.
Attachment #404717 -
Flags: approval1.9.2?
Updated•16 years ago
|
Attachment #404717 -
Flags: approval1.9.2? → approval1.9.2+
| Assignee | ||
Comment 3•16 years ago
|
||
status1.9.2:
--- → beta1-fixed
| Assignee | ||
Updated•16 years ago
|
Attachment #404717 -
Flags: approval1.9.1.5?
Comment 4•16 years ago
|
||
Comment on attachment 404717 [details] [diff] [review]
patch
> * @return capacity of the deque
> * If the deque did not grow,
> * and you knew its capacity beforehand,
> * then this would be a way to indicate the failure.
> */
>-PRInt32 nsDeque::GrowCapacity() {
>+PRBool nsDeque::GrowCapacity() {
Could you fix up the comment to match the new return value? Thanks
Approved for 1.9.1.5, a=dveditz for release-drivers
Attachment #404717 -
Flags: approval1.9.1.5? → approval1.9.1.5+
| Assignee | ||
Comment 5•16 years ago
|
||
| Assignee | ||
Comment 6•16 years ago
|
||
http://hg.mozilla.org/releases/mozilla-1.9.1/rev/b3078ea11041
(with comment fix rolled in)
status1.9.1:
--- → .5-fixed
You need to log in
before you can comment on or make changes to this bug.
Description
•