Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(697)

Unified Diff: mojo/edk/system/child_broker_host.cc

Issue 1548023002: Clear memory of broker related structs sent over the new Mojo EDK. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/edk/system/child_broker.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/child_broker_host.cc
diff --git a/mojo/edk/system/child_broker_host.cc b/mojo/edk/system/child_broker_host.cc
index 7d8208a23059c76428b323c86191b706ee0b64e7..20a73d9589e7812da2cf5348c5dece9b682269bd 100644
--- a/mojo/edk/system/child_broker_host.cc
+++ b/mojo/edk/system/child_broker_host.cc
@@ -74,6 +74,7 @@ void ChildBrokerHost::ConnectToProcess(base::ProcessId process_id,
if (!child_channel_)
return; // Can happen at process shutdown on Windows.
ConnectToProcessMessage data;
+ memset(&data, 0, sizeof(data));
data.type = CONNECT_TO_PROCESS;
data.process_id = process_id;
scoped_ptr<MessageInTransit> message(new MessageInTransit(
@@ -94,6 +95,7 @@ void ChildBrokerHost::ConnectMessagePipe(uint64_t pipe_id,
if (!child_channel_)
return; // Can happen at process shutdown on Windows.
PeerPipeConnectedMessage data;
+ memset(&data, 0, sizeof(data));
data.type = PEER_PIPE_CONNECTED;
data.pipe_id = pipe_id;
data.process_id = process_id;
« no previous file with comments | « mojo/edk/system/child_broker.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698