Closed Bug 2089965 Opened 12 days ago Closed 5 days ago

Remove dead separator checks in nsDisplayList PrintEffects debug dumps

Categories

(Core :: Web Painting, task)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: Sylvestre, Assigned: mirko, Mentored)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug, Whiteboard: [lang=c++])

Attachments

(1 external file)

Filing as a good first bug to learn workflows.

In nsDisplayFilters::PrintEffects and nsDisplayMasksAndClipPaths::PrintEffects (debug dumps), first is always true at the first if (!first) test, so that separator branch can never run. Remove the dead check in each function.

Current code:

  if (clipPathFrame) {
    if (!first) {
      aTo += ", ";

Link to the code:
https://searchfox.org/firefox-main/source/layout/painting/nsDisplayList.cpp

To verify the fix:

./mach build

This was reported by Coverity Scan (CIDs 1496226, 1496579). The analyzer will stop reporting it once the change lands.

Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html
https://firefox-source-docs.mozilla.org/contributing/stack_quickref.html

Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.

Assignee: nobody → mirko
Status: NEW → ASSIGNED
Pushed by tnikkel@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/3c0fdd372065 https://hg.mozilla.org/integration/autoland/rev/b0cff9f9e691 Remove dead separator checks in display list effect dumps. r=tnikkel,layout-reviewers
Status: ASSIGNED → RESOLVED
Closed: 5 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: