OLD | NEW |
1 // Copyright 2014 The Crashpad Authors. All rights reserved. | 1 // Copyright 2014 The Crashpad Authors. All rights reserved. |
2 // | 2 // |
3 // Licensed under the Apache License, Version 2.0 (the "License"); | 3 // Licensed under the Apache License, Version 2.0 (the "License"); |
4 // you may not use this file except in compliance with the License. | 4 // you may not use this file except in compliance with the License. |
5 // You may obtain a copy of the License at | 5 // You may obtain a copy of the License at |
6 // | 6 // |
7 // http://www.apache.org/licenses/LICENSE-2.0 | 7 // http://www.apache.org/licenses/LICENSE-2.0 |
8 // | 8 // |
9 // Unless required by applicable law or agreed to in writing, software | 9 // Unless required by applicable law or agreed to in writing, software |
10 // distributed under the License is distributed on an "AS IS" BASIS, | 10 // distributed under the License is distributed on an "AS IS" BASIS, |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 | 97 |
98 protected: | 98 protected: |
99 ~Interface() {} | 99 ~Interface() {} |
100 }; | 100 }; |
101 | 101 |
102 explicit ExcServer(Interface* interface); | 102 explicit ExcServer(Interface* interface); |
103 | 103 |
104 // MachMessageServer::Interface: | 104 // MachMessageServer::Interface: |
105 | 105 |
106 virtual bool MachMessageServerFunction( | 106 virtual bool MachMessageServerFunction( |
107 mach_msg_header_t* in_header, | 107 const mach_msg_header_t* in_header, |
108 mach_msg_header_t* out_header, | 108 mach_msg_header_t* out_header, |
109 bool* destroy_complex_request) override; | 109 bool* destroy_complex_request) override; |
110 | 110 |
111 virtual mach_msg_size_t MachMessageServerRequestSize() override; | 111 virtual mach_msg_size_t MachMessageServerRequestSize() override; |
112 virtual mach_msg_size_t MachMessageServerReplySize() override; | 112 virtual mach_msg_size_t MachMessageServerReplySize() override; |
113 | 113 |
114 private: | 114 private: |
115 Interface* interface_; // weak | 115 Interface* interface_; // weak |
116 }; | 116 }; |
117 | 117 |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 | 185 |
186 protected: | 186 protected: |
187 ~Interface() {} | 187 ~Interface() {} |
188 }; | 188 }; |
189 | 189 |
190 explicit MachExcServer(Interface* interface); | 190 explicit MachExcServer(Interface* interface); |
191 | 191 |
192 // MachMessageServer::Interface: | 192 // MachMessageServer::Interface: |
193 | 193 |
194 virtual bool MachMessageServerFunction( | 194 virtual bool MachMessageServerFunction( |
195 mach_msg_header_t* in_header, | 195 const mach_msg_header_t* in_header, |
196 mach_msg_header_t* out_header, | 196 mach_msg_header_t* out_header, |
197 bool* destroy_complex_request) override; | 197 bool* destroy_complex_request) override; |
198 | 198 |
199 virtual mach_msg_size_t MachMessageServerRequestSize() override; | 199 virtual mach_msg_size_t MachMessageServerRequestSize() override; |
200 virtual mach_msg_size_t MachMessageServerReplySize() override; | 200 virtual mach_msg_size_t MachMessageServerReplySize() override; |
201 | 201 |
202 private: | 202 private: |
203 Interface* interface_; // weak | 203 Interface* interface_; // weak |
204 }; | 204 }; |
205 | 205 |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
395 class UniversalMachExcServer | 395 class UniversalMachExcServer |
396 : public MachMessageServer::Interface, | 396 : public MachMessageServer::Interface, |
397 public internal::SimplifiedExcServer::Interface, | 397 public internal::SimplifiedExcServer::Interface, |
398 public internal::SimplifiedMachExcServer::Interface { | 398 public internal::SimplifiedMachExcServer::Interface { |
399 public: | 399 public: |
400 UniversalMachExcServer(); | 400 UniversalMachExcServer(); |
401 | 401 |
402 // MachMessageServer::Interface: | 402 // MachMessageServer::Interface: |
403 | 403 |
404 virtual bool MachMessageServerFunction( | 404 virtual bool MachMessageServerFunction( |
405 mach_msg_header_t* in_header, | 405 const mach_msg_header_t* in_header, |
406 mach_msg_header_t* out_header, | 406 mach_msg_header_t* out_header, |
407 bool* destroy_complex_request) override; | 407 bool* destroy_complex_request) override; |
408 | 408 |
409 virtual mach_msg_size_t MachMessageServerRequestSize() override; | 409 virtual mach_msg_size_t MachMessageServerRequestSize() override; |
410 virtual mach_msg_size_t MachMessageServerReplySize() override; | 410 virtual mach_msg_size_t MachMessageServerReplySize() override; |
411 | 411 |
412 // internal::SimplifiedExcServer::Interface: | 412 // internal::SimplifiedExcServer::Interface: |
413 | 413 |
414 virtual kern_return_t CatchException( | 414 virtual kern_return_t CatchException( |
415 exception_behavior_t behavior, | 415 exception_behavior_t behavior, |
(...skipping 11 matching lines...) Expand all Loading... |
427 bool* destroy_complex_request) override; | 427 bool* destroy_complex_request) override; |
428 | 428 |
429 private: | 429 private: |
430 internal::SimplifiedExcServer exc_server_; | 430 internal::SimplifiedExcServer exc_server_; |
431 internal::SimplifiedMachExcServer mach_exc_server_; | 431 internal::SimplifiedMachExcServer mach_exc_server_; |
432 }; | 432 }; |
433 | 433 |
434 } // namespace crashpad | 434 } // namespace crashpad |
435 | 435 |
436 #endif // CRASHPAD_UTIL_MACH_EXC_SERVER_VARIANTS_H_ | 436 #endif // CRASHPAD_UTIL_MACH_EXC_SERVER_VARIANTS_H_ |
OLD | NEW |