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 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 kOptionHelp = -2, | 74 kOptionHelp = -2, |
75 kOptionVersion = -3, | 75 kOptionVersion = -3, |
76 }; | 76 }; |
77 | 77 |
78 struct { | 78 struct { |
79 Operation operation; | 79 Operation operation; |
80 std::string job_label; | 80 std::string job_label; |
81 std::vector<std::string> mach_services; | 81 std::vector<std::string> mach_services; |
82 } options = {}; | 82 } options = {}; |
83 | 83 |
84 const struct option long_options[] = { | 84 const option long_options[] = { |
85 {"load", no_argument, nullptr, kOptionLoadJob}, | 85 {"load", no_argument, nullptr, kOptionLoadJob}, |
86 {"unload", no_argument, nullptr, kOptionUnloadJob}, | 86 {"unload", no_argument, nullptr, kOptionUnloadJob}, |
87 {"label", required_argument, nullptr, kOptionJobLabel}, | 87 {"label", required_argument, nullptr, kOptionJobLabel}, |
88 {"mach-service", required_argument, nullptr, kOptionMachService}, | 88 {"mach-service", required_argument, nullptr, kOptionMachService}, |
89 {"help", no_argument, nullptr, kOptionHelp}, | 89 {"help", no_argument, nullptr, kOptionHelp}, |
90 {"version", no_argument, nullptr, kOptionVersion}, | 90 {"version", no_argument, nullptr, kOptionVersion}, |
91 {nullptr, 0, nullptr, 0}, | 91 {nullptr, 0, nullptr, 0}, |
92 }; | 92 }; |
93 | 93 |
94 int opt; | 94 int opt; |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 } | 188 } |
189 } | 189 } |
190 } | 190 } |
191 | 191 |
192 } // namespace | 192 } // namespace |
193 } // namespace crashpad | 193 } // namespace crashpad |
194 | 194 |
195 int main(int argc, char* argv[]) { | 195 int main(int argc, char* argv[]) { |
196 return crashpad::OnDemandServiceToolMain(argc, argv); | 196 return crashpad::OnDemandServiceToolMain(argc, argv); |
197 } | 197 } |
OLD | NEW |