Closed Bug 1105867 Opened 5 years ago Closed 5 years ago

Fix -Wunused-const-variable warnings-as-errors in nonunified build of dom/media/webm

Categories

(Core :: Audio/Video, defect)

x86
macOS
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla37
Tracking Status
firefox35 --- unaffected
firefox36 --- fixed

People

(Reporter: cpeterson, Assigned: cpeterson)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

1. NS_PER_USEC and NS_PER_S are defined in both WebMReader.h and SoftwareWebMVideoDecoder.cpp, which causes these unused variable warnings:

> dom/media/webm/SoftwareWebMVideoDecoder.cpp:24:23: error: unused variable 'NS_PER_USEC' [-Werror,-Wunused-const-variable]
> dom/media/webm/SoftwareWebMVideoDecoder.cpp:25:23: error: unused variable 'NS_PER_S' [-Werror,-Wunused-const-variable]

2. WebMReader.h's defines NS_PER_S as a double, but SoftwareWebMVideoDecoder.cpp defines NS_PER_S as an unsigned (int). Which type is correct?

3. WebMReader.h is #included by both the SoftwareWebMVideoDecoder.h and SoftwareWebMVideoDecoder.cpp (and IntelWebMVideoDecoder.h and .cpp). This patch removes the redundant #includes from the .cpp files.
Attachment #8529946 - Flags: review?(cpearce)
Comment on attachment 8529946 [details] [diff] [review]
webm_Wunused-const-variable.patch

Review of attachment 8529946 [details] [diff] [review]:
-----------------------------------------------------------------

-> Matthew...
Attachment #8529946 - Flags: review?(cpearce) → review?(kinetik)
Comment on attachment 8529946 [details] [diff] [review]
webm_Wunused-const-variable.patch

Review of attachment 8529946 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks.
Attachment #8529946 - Flags: review?(kinetik) → review+
https://hg.mozilla.org/mozilla-central/rev/bfe4061fffde
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
You need to log in before you can comment on or make changes to this bug.