diff --git a/dom/plugins/base/nsNPAPIPlugin.cpp b/dom/plugins/base/nsNPAPIPlugin.cpp index 8882916b4f4a..7caab1bc04ed 100644 --- a/dom/plugins/base/nsNPAPIPlugin.cpp +++ b/dom/plugins/base/nsNPAPIPlugin.cpp @@ -693,7 +693,6 @@ AsyncCallbackAutoLock::~AsyncCallbackAutoLock() } } - NPP NPPStack::sCurrentNPP = nullptr; const char * @@ -744,7 +743,6 @@ _geturl(NPP npp, const char* relativeURL, const char* target) (strncmp(relativeURL, "ftp:", 4) != 0)) { nsNPAPIPluginInstance *inst = (nsNPAPIPluginInstance *) npp->ndata; - const char *name = nullptr; RefPtr host = nsPluginHost::GetInst(); host->GetPluginName(inst, &name); @@ -1958,9 +1956,7 @@ _getvalue(NPP npp, NPNVariable variable, void *result) return NPERR_NO_ERROR; } } - else { - return NPERR_GENERIC_ERROR; - } + return NPERR_GENERIC_ERROR; } #ifndef NP_NO_QUICKDRAW @@ -2189,14 +2185,13 @@ _getvalue(NPP npp, NPNVariable variable, void *result) // we no longer hand out any XPCOM objects case NPNVDOMElement: - // fall through case NPNVDOMWindow: - // fall through case NPNVserviceManager: // old XPCOM objects, no longer supported, but null out the out // param to avoid crashing plugins that still try to use this. *(nsISupports**)result = nullptr; - // fall through + MOZ_FALLTHROUGH; + default: NPN_PLUGIN_LOG(PLUGIN_LOG_NORMAL, ("NPN_getvalue unhandled get value: %d\n", variable)); return NPERR_GENERIC_ERROR; diff --git a/dom/plugins/ipc/PluginInstanceChild.cpp b/dom/plugins/ipc/PluginInstanceChild.cpp index f6dee021c5af..5802dc3cd675 100644 --- a/dom/plugins/ipc/PluginInstanceChild.cpp +++ b/dom/plugins/ipc/PluginInstanceChild.cpp @@ -502,6 +502,7 @@ PluginInstanceChild::NPN_GetValue(NPNVariable aVar, case NPNVSupportsXEmbedBool: case NPNVSupportsWindowless: NS_NOTREACHED("NPNVariable should be handled in PluginModuleChild."); + MOZ_FALLTHROUGH; #endif default: @@ -510,7 +511,6 @@ PluginInstanceChild::NPN_GetValue(NPNVariable aVar, (int) aVar, NPNVariableToString(aVar))); return NPERR_GENERIC_ERROR; } - } #ifdef MOZ_WIDGET_COCOA @@ -2313,7 +2313,6 @@ PluginInstanceChild::EnumThreadWindowsCallback(HWND hWnd, return TRUE; } - void PluginInstanceChild::SetupFlashMsgThrottle() { @@ -2610,7 +2609,6 @@ StreamNotifyChild::ActorDestroy(ActorDestroyReason why) } } - void StreamNotifyChild::SetAssociatedStream(BrowserStreamChild* bs) {