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

Side by Side Diff: content/browser/renderer_host/sandbox_ipc_linux.h

Issue 258543006: Change UnixDomainSocket::RecvMsg to return ScopedVector<base::ScopedFD> (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync and resolve conflicts with r266735 Created 6 years, 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // http://code.google.com/p/chromium/wiki/LinuxSandboxIPC 5 // http://code.google.com/p/chromium/wiki/LinuxSandboxIPC
6 6
7 #ifndef CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_ 7 #ifndef CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_
8 #define CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_ 8 #define CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_
9 9
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/files/scoped_file.h"
12 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
13 #include "base/pickle.h" 14 #include "base/pickle.h"
14 #include "content/child/blink_platform_impl.h" 15 #include "content/child/blink_platform_impl.h"
15 #include "skia/ext/skia_utils_base.h" 16 #include "skia/ext/skia_utils_base.h"
16 17
17 namespace content { 18 namespace content {
18 19
19 class SandboxIPCProcess { 20 class SandboxIPCProcess {
20 public: 21 public:
21 // lifeline_fd: this is the read end of a pipe which the browser process 22 // lifeline_fd: this is the read end of a pipe which the browser process
(...skipping 13 matching lines...) Expand all
35 private: 36 private:
36 void EnsureWebKitInitialized(); 37 void EnsureWebKitInitialized();
37 38
38 int FindOrAddPath(const SkString& path); 39 int FindOrAddPath(const SkString& path);
39 40
40 void HandleRequestFromRenderer(int fd); 41 void HandleRequestFromRenderer(int fd);
41 42
42 void HandleFontMatchRequest(int fd, 43 void HandleFontMatchRequest(int fd,
43 const Pickle& pickle, 44 const Pickle& pickle,
44 PickleIterator iter, 45 PickleIterator iter,
45 std::vector<int>& fds); 46 const std::vector<base::ScopedFD*>& fds);
46 47
47 void HandleFontOpenRequest(int fd, 48 void HandleFontOpenRequest(int fd,
48 const Pickle& pickle, 49 const Pickle& pickle,
49 PickleIterator iter, 50 PickleIterator iter,
50 std::vector<int>& fds); 51 const std::vector<base::ScopedFD*>& fds);
51 52
52 void HandleGetFontFamilyForChar(int fd, 53 void HandleGetFontFamilyForChar(int fd,
53 const Pickle& pickle, 54 const Pickle& pickle,
54 PickleIterator iter, 55 PickleIterator iter,
55 std::vector<int>& fds); 56 const std::vector<base::ScopedFD*>& fds);
56 57
57 void HandleGetStyleForStrike(int fd, 58 void HandleGetStyleForStrike(int fd,
58 const Pickle& pickle, 59 const Pickle& pickle,
59 PickleIterator iter, 60 PickleIterator iter,
60 std::vector<int>& fds); 61 const std::vector<base::ScopedFD*>& fds);
61 62
62 void HandleLocaltime(int fd, 63 void HandleLocaltime(int fd,
63 const Pickle& pickle, 64 const Pickle& pickle,
64 PickleIterator iter, 65 PickleIterator iter,
65 std::vector<int>& fds); 66 const std::vector<base::ScopedFD*>& fds);
66 67
67 void HandleGetChildWithInode(int fd, 68 void HandleGetChildWithInode(int fd,
68 const Pickle& pickle, 69 const Pickle& pickle,
69 PickleIterator iter, 70 PickleIterator iter,
70 std::vector<int>& fds); 71 const std::vector<base::ScopedFD*>& fds);
71 72
72 void HandleMakeSharedMemorySegment(int fd, 73 void HandleMakeSharedMemorySegment(int fd,
73 const Pickle& pickle, 74 const Pickle& pickle,
74 PickleIterator iter, 75 PickleIterator iter,
75 std::vector<int>& fds); 76 const std::vector<base::ScopedFD*>& fds);
76 77
77 void HandleMatchWithFallback(int fd, 78 void HandleMatchWithFallback(int fd,
78 const Pickle& pickle, 79 const Pickle& pickle,
79 PickleIterator iter, 80 PickleIterator iter,
80 std::vector<int>& fds); 81 const std::vector<base::ScopedFD*>& fds);
81 82
82 void SendRendererReply(const std::vector<int>& fds, 83 void SendRendererReply(const std::vector<base::ScopedFD*>& fds,
83 const Pickle& reply, 84 const Pickle& reply,
84 int reply_fd); 85 int reply_fd);
85 86
86 const int lifeline_fd_; 87 const int lifeline_fd_;
87 const int browser_socket_; 88 const int browser_socket_;
88 std::vector<std::string> sandbox_cmd_; 89 std::vector<std::string> sandbox_cmd_;
89 scoped_ptr<BlinkPlatformImpl> webkit_platform_support_; 90 scoped_ptr<BlinkPlatformImpl> webkit_platform_support_;
90 SkTDArray<SkString*> paths_; 91 SkTDArray<SkString*> paths_;
91 92
92 DISALLOW_COPY_AND_ASSIGN(SandboxIPCProcess); 93 DISALLOW_COPY_AND_ASSIGN(SandboxIPCProcess);
93 }; 94 };
94 95
95 } // namespace content 96 } // namespace content
96 97
97 #endif // CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_ 98 #endif // CONTENT_BROWSER_RENDERER_HOST_SANDBOX_IPC_H_
OLDNEW
« no previous file with comments | « components/nacl/zygote/nacl_fork_delegate_linux.cc ('k') | content/browser/renderer_host/sandbox_ipc_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698