summaryrefslogtreecommitdiffstats
path: root/ppapi
diff options
context:
space:
mode:
authorddorwin@chromium.org <ddorwin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-29 23:31:29 +0000
committerddorwin@chromium.org <ddorwin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-29 23:31:29 +0000
commit0de0ad2eaeb50a0cdc37c5ca1c6106c0731e8e54 (patch)
treee38d4a8163382b4394676992eee679f0eef9d492 /ppapi
parent5912d47ca547de53404fe7762e52aaea75adc382 (diff)
downloadchromium_src-0de0ad2eaeb50a0cdc37c5ca1c6106c0731e8e54.zip
chromium_src-0de0ad2eaeb50a0cdc37c5ca1c6106c0731e8e54.tar.gz
chromium_src-0de0ad2eaeb50a0cdc37c5ca1c6106c0731e8e54.tar.bz2
Revert 103377 - Fix a pepper plugin process crash which occurs if we receive input events for a deleted plugin. This could happen
in the multi process plugin scenario where the renderer could send events for deleted plugins in the context of outgoing sync calls. Fixes bug http://code.google.com/p/flapper/issues/detail?id=87 Review URL: http://codereview.chromium.org/8073017 TBR=ananta@chromium.org Review URL: http://codereview.chromium.org/8081009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@103389 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r--ppapi/shared_impl/resource_tracker.cc12
1 files changed, 4 insertions, 8 deletions
diff --git a/ppapi/shared_impl/resource_tracker.cc b/ppapi/shared_impl/resource_tracker.cc
index 717c038..303e980 100644
--- a/ppapi/shared_impl/resource_tracker.cc
+++ b/ppapi/shared_impl/resource_tracker.cc
@@ -144,11 +144,8 @@ PP_Resource ResourceTracker::AddResource(Resource* object) {
if (found == instance_map_.end()) {
// If you hit this, it's likely somebody forgot to call DidCreateInstance,
// the resource was created with an invalid PP_Instance, or the renderer
- // side tried to create a resource for a plugin that crashed/exited. This
- // could happen for OOP plugins where due to reentrancies in context of
- // outgoing sync calls the renderer can send events after a plugin has
- // exited.
- DLOG(INFO) << "Failed to find plugin instance in instance map";
+ // side tried to create a resource for a plugin that crashed.
+ NOTREACHED();
return 0;
}
@@ -161,9 +158,8 @@ PP_Resource ResourceTracker::AddResource(Resource* object) {
void ResourceTracker::RemoveResource(Resource* object) {
PP_Resource pp_resource = object->pp_resource();
- InstanceMap::iterator found = instance_map_.find(object->pp_instance());
- if (found != instance_map_.end())
- instance_map_.erase(found);
+ if (object->pp_instance())
+ instance_map_[object->pp_instance()]->resources.erase(pp_resource);
live_resources_.erase(pp_resource);
}