Closed Bug 1883282 Opened 8 months ago Closed 5 months ago

Log message incorrectly logs split string parts

Categories

(Core :: Networking, defect, P3)

defect

Tracking

()

RESOLVED FIXED
127 Branch
Tracking Status
firefox127 --- fixed

People

(Reporter: handyman, Assigned: mike.maksymowych)

Details

(Keywords: good-first-bug, Whiteboard: [necko-triaged])

Attachments

(1 file)

The log message here is incorrect.

      for (const nsACString& suffix : list.Split(',')) {
        LOG(("  appending DNS suffix from registry: %s\n",
             suffix.BeginReading()));

nsTSubstring::Split efficiently returns substrings that aren't null-terminated. They need to be copied to a null terminated string if they are going to be used that way, e.g. with PromiseFlatCString.

Documentation on PromiseFlatCString for anyone interested in taking this bug as a good-first-bug.

Priority: -- → P3
Whiteboard: [necko-triaged]
Assignee: nobody → mike.maksymowych
Status: NEW → ASSIGNED

This good-first-bug hasn't had any activity for 2 months, it is automatically unassigned.
For more information, please visit BugBot documentation.

Assignee: mike.maksymowych → nobody
Status: ASSIGNED → NEW
Pushed by valentin.gosu@gmail.com: https://hg.mozilla.org/integration/autoland/rev/e5cc8ff6f2c0 Use PromiseFlatCString to null-terminate log. r=necko-reviewers,valentin
Assignee: nobody → mike.maksymowych
Status: NEW → ASSIGNED
Status: ASSIGNED → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 127 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: