Closed Bug 1629422 Opened 5 years ago Closed 4 years ago

MediaTransportHandler.cpp: redundant string initialization

Categories

(Developer Infrastructure :: Source Code Analysis, task)

task
Not set
minor

Tracking

(firefox78 fixed)

RESOLVED FIXED
mozilla78
Tracking Status
firefox78 --- fixed

People

(Reporter: Sylvestre, Assigned: chris.cushman, Mentored)

References

(Blocks 1 open bug)

Details

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

Attachments

(1 file)

+++ This bug was initially created as a clone of Bug #1629421 +++

Filling as a good first bug to learn workflows.

std::string alpnDefault = "";

= ""; isn't useful

https://searchfox.org/mozilla-central/source/media/webrtc/signaling/src/peerconnection/MediaTransportHandler.cpp#1189

As the change is trivial, it is just to learn how to contribute to Firefox.

Found by http://clang.llvm.org/extra/clang-tidy/checks/readability-container-size-empty.html

Tutorial to contribute:
https://firefox-source-docs.mozilla.org/tools/docs/contribute/how_to_contribute_firefox.html

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

Also, please only work on two max of such bugs.

Assignee: nobody → chris.cushman
Status: NEW → ASSIGNED

Try run here: https://treeherder.mozilla.org/#/jobs?repo=try&revision=bffe0734ac4e3bee4d88a1ffa2a217d7d361ad0d
Setting needinfo for me to follow up and land if it looks green.

Flags: needinfo?(dminor)
Attachment #9151615 - Attachment description: Bug 1629422 - elimenatting redundant string initialization from std::string alpnDefault = ""; on line 1220 → Bug 1629422 - elimenatting redundant string initialization from alpn and set it = {"c-webrtc"} upon initialization and removed redundant separate insert

Try run is fine, waiting on a typo fix in the commit message before this can land.

Flags: needinfo?(dminor)
Attachment #9151615 - Attachment description: Bug 1629422 - elimenatting redundant string initialization from alpn and set it = {"c-webrtc"} upon initialization and removed redundant separate insert → Bug 1629422 - Eliminating redundant initialization in MediaTransportHandler
Pushed by dminor@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/24f991e9f267 Eliminating redundant initialization in MediaTransportHandler r=dminor
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla78
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: