OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/common/extensions/permissions/socket_permission_data.h" | 5 #include "chrome/common/extensions/permissions/socket_permission_data.h" |
6 | 6 |
7 #include <cstdlib> | 7 #include <cstdlib> |
8 #include <sstream> | 8 #include <sstream> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "base/string_split.h" | |
14 #include "base/string_util.h" | 13 #include "base/string_util.h" |
15 #include "base/strings/string_number_conversions.h" | 14 #include "base/strings/string_number_conversions.h" |
| 15 #include "base/strings/string_split.h" |
16 #include "chrome/common/extensions/permissions/api_permission.h" | 16 #include "chrome/common/extensions/permissions/api_permission.h" |
17 #include "chrome/common/extensions/permissions/socket_permission.h" | 17 #include "chrome/common/extensions/permissions/socket_permission.h" |
18 #include "googleurl/src/url_canon.h" | 18 #include "googleurl/src/url_canon.h" |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
22 using content::SocketPermissionRequest; | 22 using content::SocketPermissionRequest; |
23 using extensions::SocketPermissionData; | 23 using extensions::SocketPermissionData; |
24 | 24 |
25 const char kColon = ':'; | 25 const char kColon = ':'; |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 | 268 |
269 void SocketPermissionData::Reset() { | 269 void SocketPermissionData::Reset() { |
270 pattern_.type = SocketPermissionRequest::NONE; | 270 pattern_.type = SocketPermissionRequest::NONE; |
271 pattern_.host.clear(); | 271 pattern_.host.clear(); |
272 match_subdomains_ = false; | 272 match_subdomains_ = false; |
273 pattern_.port = kInvalidPort; | 273 pattern_.port = kInvalidPort; |
274 spec_.clear(); | 274 spec_.clear(); |
275 } | 275 } |
276 | 276 |
277 } // namespace extensions | 277 } // namespace extensions |
OLD | NEW |