Closed Bug 143560 Opened 22 years ago Closed 22 years ago

showdependencytree.cgi eats all available memory if there's a circular dependency

Categories

(Bugzilla :: Creating/Changing Bugs, defect)

2.15
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 2.16

People

(Reporter: justdave, Assigned: myk)

References

()

Details

Attachments

(1 file)

showdependencytree.cgi eats all available memory if there's a circular dependency.

The kernel usually ends up killing the process.
This patch fixes the problem by marking the bug currently being processed as
"seen" before it recurses into the next level of the hierarchy.
Would it be better if the cgi just didn't generate the recusrive stuff to push
to the template in the first place?

ie move the second test on line 133 inside the first if statement?

Or would that be messier?
*** Bug 143634 has been marked as a duplicate of this bug. ***
Concerning the patch (attachment 83117 [details] [diff] [review]) see also bug 143634 comment 3.
I like Myk's fix. As far as I'm concerned, the data structure given to the
template reflects the reality of the database. Making it not do so in some way
(to avoid this problem) would be wrong.

Gerv
I'm having computer problems this weekend and can't check this in, so anyone is
welcome to check it in for me if it gets review before Monday.
Comment on attachment 83117 [details] [diff] [review]
patch v1: fixes problem

2xr=gerv.

Gerv
Attachment #83117 - Flags: review+
Fixed on trunk and branch.

Checking in template/en/default/bug/dependency-tree.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/bug/dependency-tree.html.tmpl,v
 <--  dependency-tree.html.tmpl
new revision: 1.4.2.1; previous revision: 1.4
done

Checking in template/en/default/bug/dependency-tree.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/bug/dependency-tree.html.tmpl,v
 <--  dependency-tree.html.tmpl
new revision: 1.5; previous revision: 1.4
done

Gerv
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Target Milestone: --- → Bugzilla 2.16
QA Contact: matty_is_a_geek → default-qa
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: