зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1240264
- Annotate intentional switch fallthroughs in dom/media/. r=cpearce
dom/media/MediaManager.cpp:1905:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels dom/media/webm/WebMBufferedParser.cpp:133:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
This commit is contained in:
Родитель
25feb9688d
Коммит
74f570e360
|
@ -1925,8 +1925,7 @@ MediaManager::GetUserMedia(nsPIDOMWindow* aWindow,
|
|||
nsPIDOMWindow *outer = aWindow->GetOuterWindow();
|
||||
vc.mBrowserWindow.Construct(outer->WindowID());
|
||||
}
|
||||
// | Fall through
|
||||
// V
|
||||
MOZ_FALLTHROUGH;
|
||||
case dom::MediaSourceEnum::Screen:
|
||||
case dom::MediaSourceEnum::Application:
|
||||
case dom::MediaSourceEnum::Window:
|
||||
|
|
|
@ -252,7 +252,7 @@ already_AddRefed<SharedThreadPool> GetMediaThreadPool(MediaThreadType aType)
|
|||
name = "MediaPDecoder";
|
||||
break;
|
||||
default:
|
||||
MOZ_ASSERT(false);
|
||||
MOZ_FALLTHROUGH_ASSERT("Unexpected MediaThreadType");
|
||||
case MediaThreadType::PLAYBACK:
|
||||
name = "MediaPlayback";
|
||||
break;
|
||||
|
|
|
@ -569,7 +569,7 @@ public:
|
|||
aPrevious->mCurve, aPrevious->mCurveLength,
|
||||
aPrevious->mDuration, aTime);
|
||||
case AudioTimelineEvent::SetTarget:
|
||||
MOZ_ASSERT(false, "unreached");
|
||||
MOZ_FALLTHROUGH_ASSERT("AudioTimelineEvent::SetTarget");
|
||||
case AudioTimelineEvent::SetValue:
|
||||
case AudioTimelineEvent::Cancel:
|
||||
case AudioTimelineEvent::Stream:
|
||||
|
@ -617,7 +617,7 @@ public:
|
|||
aPrevious->mCurve, aPrevious->mCurveLength,
|
||||
aPrevious->mDuration, aTime);
|
||||
case AudioTimelineEvent::SetTarget:
|
||||
MOZ_ASSERT(false, "unreached");
|
||||
MOZ_FALLTHROUGH_ASSERT("AudioTimelineEvent::SetTarget");
|
||||
case AudioTimelineEvent::SetValue:
|
||||
case AudioTimelineEvent::Cancel:
|
||||
case AudioTimelineEvent::Stream:
|
||||
|
|
|
@ -570,7 +570,7 @@ WebAudioDecodeJob::OnFailure(ErrorCode aErrorCode)
|
|||
const char* errorMessage;
|
||||
switch (aErrorCode) {
|
||||
case NoError:
|
||||
MOZ_ASSERT(false, "Who passed NoError to OnFailure?");
|
||||
MOZ_FALLTHROUGH_ASSERT("Who passed NoError to OnFailure?");
|
||||
// Fall through to get some sort of a sane error message if this actually
|
||||
// happens at runtime.
|
||||
case UnknownError:
|
||||
|
|
|
@ -133,7 +133,7 @@ void WebMBufferedParser::Append(const unsigned char* aBuffer, uint32_t aLength,
|
|||
case EBML_ID:
|
||||
mLastInitStartOffset = mCurrentOffset + (p - aBuffer) -
|
||||
(mElement.mID.mLength + mElement.mSize.mLength);
|
||||
/* FALLTHROUGH */
|
||||
MOZ_FALLTHROUGH;
|
||||
default:
|
||||
mSkipBytes = mElement.mSize.mValue;
|
||||
mState = SKIP_DATA;
|
||||
|
|
Загрузка…
Ссылка в новой задаче