Closed Bug 468209 Opened 16 years ago Closed 16 years ago

_removeRowsFromHistory is broken

Categories

(Firefox :: Bookmarks & History, defect, P2)

defect

Tracking

()

VERIFIED FIXED
Firefox 3.1b3

People

(Reporter: Gavin, Assigned: mak)

References

Details

(Keywords: perf, verified1.9.1)

Attachments

(1 file)

From bug 382187 comment #58: > >+ var URIslice = URIs.slice(i, Math.max(i + REMOVE_PAGES_CHUNKLEN, URIs.length)); > Whoa, this should be Math.min As far as I can tell this means the first loop removes all of aURIs, and the subsequent iterations call removePages for progressively smaller chunks of already removed URIs. As Neil pointed out in the bug, the Math.min isn't necessary at all, you can just always pass in i + REMOVE_PAGES_CHUNKLEN.
Flags: blocking-firefox3.1?
The practical effects of this bug that I forgot to mention in comment 0 is that deleting a lot of history items is slower than it needs to be, and potentially causes the browser to lock up or show a slow script warning.
In fact, this might be the cause of bug 466421.
Blocks: 466421
many thanks!
Assignee: nobody → mak77
Status: NEW → ASSIGNED
Hwv this won't solve the slow script, that is mostly due to persisting selection in the treeView (see _refreshVisibleSection, we can take a look there in bug 466421), hwv it is reducing them a lot, for removing 16000 items i get only 1 slow script now (due to the final loop that do a batch notify that updates the treeview).
Attached patch patch (deleted) — Splinter Review
Attachment #351677 - Flags: review?(dietrich)
Target Milestone: --- → Firefox 3.1
Attachment #351677 - Flags: review?(dietrich) → review+
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Comment on attachment 351677 [details] [diff] [review] patch approval or blocking please, this was broken code.
Attachment #351677 - Flags: approval1.9.1?
Flags: blocking-firefox3.1? → blocking-firefox3.1+
Keywords: perf
Priority: -- → P2
Attachment #351677 - Flags: approval1.9.1?
Target Milestone: Firefox 3.1 → Firefox 3.1b3
verified with Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b3pre) Gecko/20090127 Shiretoko/3.1b3pre
Status: RESOLVED → VERIFIED
Bug 451915 - move Firefox/Places bugs to Firefox/Bookmarks and History. Remove all bugspam from this move by filtering for the string "places-to-b-and-h". In Thunderbird 3.0b, you do that as follows: Tools | Message Filters Make sure the correct account is selected. Click "New" Conditions: Body contains places-to-b-and-h Change the action to "Delete Message". Select "Manually Run" from the dropdown at the top. Click OK. Select the filter in the list, make sure "Inbox" is selected at the bottom, and click "Run Now". This should delete all the bugspam. You can then delete the filter. Gerv
Component: Places → Bookmarks & History
QA Contact: places → bookmarks
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: