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

Side by Side Diff: ipc/attachment_broker_privileged_win.cc

Issue 1770013002: Replace base::Tuple in //ipc with std::tuple (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: +#include Created 4 years, 9 months 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ipc/attachment_broker_privileged_win.h" 5 #include "ipc/attachment_broker_privileged_win.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 8
9 #include <tuple>
10
9 #include "base/process/process.h" 11 #include "base/process/process.h"
10 #include "ipc/attachment_broker_messages.h" 12 #include "ipc/attachment_broker_messages.h"
11 #include "ipc/brokerable_attachment.h" 13 #include "ipc/brokerable_attachment.h"
12 #include "ipc/handle_attachment_win.h" 14 #include "ipc/handle_attachment_win.h"
13 #include "ipc/ipc_channel.h" 15 #include "ipc/ipc_channel.h"
14 16
15 namespace IPC { 17 namespace IPC {
16 18
17 AttachmentBrokerPrivilegedWin::AttachmentBrokerPrivilegedWin() {} 19 AttachmentBrokerPrivilegedWin::AttachmentBrokerPrivilegedWin() {}
18 20
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 } 54 }
53 return handled; 55 return handled;
54 } 56 }
55 57
56 void AttachmentBrokerPrivilegedWin::OnDuplicateWinHandle( 58 void AttachmentBrokerPrivilegedWin::OnDuplicateWinHandle(
57 const IPC::Message& message) { 59 const IPC::Message& message) {
58 AttachmentBrokerMsg_DuplicateWinHandle::Param param; 60 AttachmentBrokerMsg_DuplicateWinHandle::Param param;
59 if (!AttachmentBrokerMsg_DuplicateWinHandle::Read(&message, &param)) 61 if (!AttachmentBrokerMsg_DuplicateWinHandle::Read(&message, &param))
60 return; 62 return;
61 IPC::internal::HandleAttachmentWin::WireFormat wire_format = 63 IPC::internal::HandleAttachmentWin::WireFormat wire_format =
62 base::get<0>(param); 64 std::get<0>(param);
63 65
64 if (wire_format.destination_process == base::kNullProcessId) { 66 if (wire_format.destination_process == base::kNullProcessId) {
65 LogError(NO_DESTINATION); 67 LogError(NO_DESTINATION);
66 return; 68 return;
67 } 69 }
68 70
69 HandleWireFormat new_wire_format = 71 HandleWireFormat new_wire_format =
70 DuplicateWinHandle(wire_format, message.get_sender_pid()); 72 DuplicateWinHandle(wire_format, message.get_sender_pid());
71 RouteDuplicatedHandle(new_wire_format); 73 RouteDuplicatedHandle(new_wire_format);
72 } 74 }
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 149
148 AttachmentBrokerPrivilegedWin::HandleWireFormat 150 AttachmentBrokerPrivilegedWin::HandleWireFormat
149 AttachmentBrokerPrivilegedWin::CopyWireFormat( 151 AttachmentBrokerPrivilegedWin::CopyWireFormat(
150 const HandleWireFormat& wire_format, 152 const HandleWireFormat& wire_format,
151 int handle) { 153 int handle) {
152 return HandleWireFormat(handle, wire_format.destination_process, 154 return HandleWireFormat(handle, wire_format.destination_process,
153 wire_format.permissions, wire_format.attachment_id); 155 wire_format.permissions, wire_format.attachment_id);
154 } 156 }
155 157
156 } // namespace IPC 158 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/attachment_broker_privileged_mac.cc ('k') | ipc/attachment_broker_privileged_win_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698