Closed Bug 385876 Opened 17 years ago Closed 17 years ago

DM should cache the query that nsDownload::UpdateDB uses

Categories

(Toolkit :: Downloads API, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.9alpha7

People

(Reporter: sdwilsh, Assigned: sciguyryan)

Details

Attachments

(1 file, 1 obsolete file)

When downloading, it can get called once every 400ms.  We can toss this in a member variable in nsDownloadManager and create it in Init (or lazily create it) instead of creating it each and ever single time.
Assignee: nobody → sciguyryan
Status: NEW → ASSIGNED
Attached patch Patch v1.0 (obsolete) — Splinter Review
Patch v1.0

Like so?
Attachment #270417 - Flags: review?(sdwilsh)
Comment on attachment 270417 [details] [diff] [review]
Patch v1.0

Nearly - please remove this too:
http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/toolkit/components/downloads/src/nsDownloadManager.cpp&rev=1.92#66

Did you by chance run the unit tests for this component?
Attachment #270417 - Flags: review?(sdwilsh) → review+
Attached patch Patch v1.1Splinter Review
Patch v1.1

Updated to tip.
Attachment #270417 - Attachment is obsolete: true
Attachment #270423 - Flags: review+
Whiteboard: [checkin needed]
Flags: in-testsuite-
Target Milestone: --- → Firefox 3 beta1
Checking in toolkit/components/downloads/src/nsDownloadManager.h;
new revision: 1.30; previous revision: 1.29
Checking in toolkit/components/downloads/src/nsDownloadManager.cpp;
new revision: 1.94; previous revision: 1.93
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Whiteboard: [checkin needed]
Product: Firefox → Toolkit
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: