Index: sandbox/linux/syscall_broker/broker_host.cc |
diff --git a/sandbox/linux/syscall_broker/broker_host.cc b/sandbox/linux/syscall_broker/broker_host.cc |
index 7ebc7850a0f4da1e4fc781db9441bf6b6060d0a7..ca55f211598c5fbbd7d9e87fcfd54561c0b9b544 100644 |
--- a/sandbox/linux/syscall_broker/broker_host.cc |
+++ b/sandbox/linux/syscall_broker/broker_host.cc |
@@ -110,21 +110,18 @@ void AccessFileForIPC(const BrokerPolicy& policy, |
} |
} |
-// Handle a |command_type| request contained in |read_pickle| and send the reply |
+// Handle a |command_type| request contained in |iter| and send the reply |
// on |reply_ipc|. |
// Currently COMMAND_OPEN and COMMAND_ACCESS are supported. |
bool HandleRemoteCommand(const BrokerPolicy& policy, |
IPCCommand command_type, |
int reply_ipc, |
- const Pickle& read_pickle, |
PickleIterator iter) { |
// Currently all commands have two arguments: filename and flags. |
std::string requested_filename; |
int flags = 0; |
- if (!read_pickle.ReadString(&iter, &requested_filename) || |
- !read_pickle.ReadInt(&iter, &flags)) { |
+ if (!iter.ReadString(&requested_filename) || !iter.ReadInt(&flags)) |
return false; |
- } |
Pickle write_pickle; |
std::vector<int> opened_files; |
@@ -200,7 +197,7 @@ BrokerHost::RequestStatus BrokerHost::HandleRequest() const { |
Pickle pickle(buf, msg_len); |
PickleIterator iter(pickle); |
int command_type; |
- if (pickle.ReadInt(&iter, &command_type)) { |
+ if (iter.ReadInt(&command_type)) { |
bool command_handled = false; |
// Go through all the possible IPC messages. |
switch (command_type) { |
@@ -209,7 +206,7 @@ BrokerHost::RequestStatus BrokerHost::HandleRequest() const { |
// We reply on the file descriptor sent to us via the IPC channel. |
command_handled = HandleRemoteCommand( |
broker_policy_, static_cast<IPCCommand>(command_type), |
- temporary_ipc.get(), pickle, iter); |
+ temporary_ipc.get(), iter); |
break; |
default: |
NOTREACHED(); |