browser-plugin: Fix the browser plugin
commit 26991988cb
broke the browser plugin
by trying to reference a uninitialized pointer and making the NPAPI retain
a NULL object.
https://bugzilla.gnome.org/show_bug.cgi?id=668517
This commit is contained in:
parent
73261a4a66
commit
2c9e6bb589
@ -822,8 +822,8 @@ plugin_object_set_callback (NPObject **listener,
|
||||
|
||||
if (NPVARIANT_IS_OBJECT (*value))
|
||||
{
|
||||
funcs.retainobject (*listener);
|
||||
*listener = NPVARIANT_TO_OBJECT (*value);
|
||||
funcs.retainobject (*listener);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
@ -836,6 +836,8 @@ plugin_object_set_property (NPObject *npobj,
|
||||
{
|
||||
PluginObject *obj;
|
||||
|
||||
obj = (PluginObject *)npobj;
|
||||
|
||||
if (name == onextension_changed_id)
|
||||
return plugin_object_set_callback (&obj->listener, value);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user