mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 12:55:46 +00:00
Null pointer check if no default plugin. part of patch for bug 54437 a=av sr=buster
This commit is contained in:
parent
0402acedf2
commit
8d852ff6bc
@ -2487,8 +2487,11 @@ nsPluginInstanceOwner::HandleEvent(nsIDOMEvent* aEvent)
|
|||||||
nsEventStatus nsPluginInstanceOwner::ProcessEvent(const nsGUIEvent& anEvent)
|
nsEventStatus nsPluginInstanceOwner::ProcessEvent(const nsGUIEvent& anEvent)
|
||||||
{
|
{
|
||||||
nsEventStatus rv = nsEventStatus_eIgnore;
|
nsEventStatus rv = nsEventStatus_eIgnore;
|
||||||
|
if (!mInstance) // if mInstance is null, we shouldn't be here
|
||||||
|
return rv;
|
||||||
|
|
||||||
#ifdef XP_MAC
|
#ifdef XP_MAC
|
||||||
if (mInstance != NULL) {
|
if (mWidget != NULL) { // check for null mWidget
|
||||||
EventRecord* event = (EventRecord*)anEvent.nativeMsg;
|
EventRecord* event = (EventRecord*)anEvent.nativeMsg;
|
||||||
if (event == NULL || event->what == nullEvent) {
|
if (event == NULL || event->what == nullEvent) {
|
||||||
EventRecord macEvent;
|
EventRecord macEvent;
|
||||||
|
@ -2487,8 +2487,11 @@ nsPluginInstanceOwner::HandleEvent(nsIDOMEvent* aEvent)
|
|||||||
nsEventStatus nsPluginInstanceOwner::ProcessEvent(const nsGUIEvent& anEvent)
|
nsEventStatus nsPluginInstanceOwner::ProcessEvent(const nsGUIEvent& anEvent)
|
||||||
{
|
{
|
||||||
nsEventStatus rv = nsEventStatus_eIgnore;
|
nsEventStatus rv = nsEventStatus_eIgnore;
|
||||||
|
if (!mInstance) // if mInstance is null, we shouldn't be here
|
||||||
|
return rv;
|
||||||
|
|
||||||
#ifdef XP_MAC
|
#ifdef XP_MAC
|
||||||
if (mInstance != NULL) {
|
if (mWidget != NULL) { // check for null mWidget
|
||||||
EventRecord* event = (EventRecord*)anEvent.nativeMsg;
|
EventRecord* event = (EventRecord*)anEvent.nativeMsg;
|
||||||
if (event == NULL || event->what == nullEvent) {
|
if (event == NULL || event->what == nullEvent) {
|
||||||
EventRecord macEvent;
|
EventRecord macEvent;
|
||||||
|
Loading…
Reference in New Issue
Block a user