Closed Bug 377577 Opened 17 years ago Closed 17 years ago

Trees are limited to a depth of 32

Categories

(Core :: XUL, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: neil, Assigned: neil)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

While investigating bug 73296 I discovered a hard-coded limit of 32 on the depth of a tree. Unfortunately the test case no longer exists.
Attached patch Proposed patchSplinter Review
I changed mLink into an nsAutoTArray which eliminates mTop too.

I picked the initial size of the array based on the old kMaxDepth but I guess it would probably be better to choose a smaller value or use an nsTArray.
Assignee: Jan.Varga → neil
Status: NEW → ASSIGNED
Attachment #261613 - Flags: review?(enndeakin)
Comment on attachment 261613 [details] [diff] [review]
Proposed patch

Looks OK.

The only comment might be to change the error message in Append/Push.
Attachment #261613 - Flags: review?(enndeakin) → review+
Attachment #261613 - Flags: superreview?(roc)
Comment on attachment 261613 [details] [diff] [review]
Proposed patch

+    return PRBool(GetTop() == aIterator.GetTop());

Not your code, but this PRBool cast is unnecessary
Attachment #261613 - Flags: superreview?(roc) → superreview+
Fix checked in.
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Flags: in-testsuite?
Component: XP Toolkit/Widgets: Trees → XUL
QA Contact: xptoolkit.trees → xptoolkit.widgets
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: