diff options
author | cevans@chromium.org <cevans@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-05 15:19:04 +0000 |
---|---|---|
committer | cevans@chromium.org <cevans@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-05 15:19:04 +0000 |
commit | f3071247741d3c88d52c06613061e7f03a833769 (patch) | |
tree | 0af938d36f3ac61c6ee123f0266b3154913d08c3 | |
parent | fdbe105e55a422937d777e814fea4c963646cd30 (diff) | |
download | chromium_src-f3071247741d3c88d52c06613061e7f03a833769.zip chromium_src-f3071247741d3c88d52c06613061e7f03a833769.tar.gz chromium_src-f3071247741d3c88d52c06613061e7f03a833769.tar.bz2 |
Avoid out-of-bounds array access.
TEST=NONE
BUG=34710
Review URL: http://codereview.chromium.org/572031
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38209 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/worker_host/worker_process_host.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chrome/browser/worker_host/worker_process_host.cc b/chrome/browser/worker_host/worker_process_host.cc index 4f6d5ae..9dbfe05 100644 --- a/chrome/browser/worker_host/worker_process_host.cc +++ b/chrome/browser/worker_host/worker_process_host.cc @@ -287,7 +287,8 @@ void WorkerProcessHost::RelayMessage( &message, &msg, &sent_message_port_ids, &new_routing_ids)) { return; } - DCHECK(sent_message_port_ids.size() == new_routing_ids.size()); + if (sent_message_port_ids.size() != new_routing_ids.size()) + return; for (size_t i = 0; i < sent_message_port_ids.size(); ++i) { new_routing_ids[i] = next_route_id->Run(); |