Remove null checks after constructors in VideoDocument.cpp

RESOLVED FIXED in mozilla11

Status

()

Core
Audio/Video
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: jaws, Assigned: Tobbi)

Tracking

Trunk
mozilla11
Points:
---
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [good first bug][mentor=Ms2ger])

Attachments

(1 attachment)

> mozilla::dom::VideoDocument* doc = new mozilla::dom::VideoDocument();
> NS_ENSURE_TRUE(doc, NS_ERROR_OUT_OF_MEMORY);

These checks are unnecessary since we are not using |new (std::nothrow)|.

http://mxr.mozilla.org/mozilla-central/source/content/html/document/src/VideoDocument.cpp#161

http://mxr.mozilla.org/mozilla-central/source/content/html/document/src/VideoDocument.cpp#87

Updated

6 years ago
Blocks: 457262
No longer depends on: 457262
Whiteboard: [good first bug][mentor=Ms2ger]
(Assignee)

Comment 1

6 years ago
Created attachment 578019 [details] [diff] [review]
patch
Assignee: nobody → tobbi.bugs
Status: NEW → ASSIGNED
Attachment #578019 - Flags: review?(jwein)
Comment on attachment 578019 [details] [diff] [review]
patch

Looks good to me, but I can't review this. I've forwarded the review to Olli.
Attachment #578019 - Flags: review?(jwein)
Attachment #578019 - Flags: review?(bugs)
Attachment #578019 - Flags: feedback+

Updated

6 years ago
Attachment #578019 - Flags: review?(bugs) → review+

Updated

6 years ago
Keywords: checkin-needed
https://hg.mozilla.org/integration/mozilla-inbound/rev/62df7e3891cd
Flags: in-testsuite-
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/62df7e3891cd
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla11
You need to log in before you can comment on or make changes to this bug.