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

Side by Side Diff: content/browser/geolocation/wifi_data_provider_corewlan_mac.mm

Issue 1874893002: Convert //content/browser from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Implements a WLAN API binding for CoreWLAN, as available on OSX 10.6 5 // Implements a WLAN API binding for CoreWLAN, as available on OSX 10.6
6 6
7 #include "content/browser/geolocation/wifi_data_provider_mac.h" 7 #include "content/browser/geolocation/wifi_data_provider_mac.h"
8 8
9 #include <dlfcn.h> 9 #include <dlfcn.h>
10 #import <Foundation/Foundation.h> 10 #import <Foundation/Foundation.h>
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 5, 175 5,
176 6); 176 6);
177 177
178 // Return true even if some interfaces failed to scan, so long as at least 178 // Return true even if some interfaces failed to scan, so long as at least
179 // one interface did not fail. 179 // one interface did not fail.
180 return interface_error_count == 0 || 180 return interface_error_count == 0 ||
181 [supported_interfaces count] > interface_error_count; 181 [supported_interfaces count] > interface_error_count;
182 } 182 }
183 183
184 WifiDataProviderCommon::WlanApiInterface* NewCoreWlanApi() { 184 WifiDataProviderCommon::WlanApiInterface* NewCoreWlanApi() {
185 scoped_ptr<CoreWlanApi> self(new CoreWlanApi); 185 std::unique_ptr<CoreWlanApi> self(new CoreWlanApi);
186 if (self->Init()) 186 if (self->Init())
187 return self.release(); 187 return self.release();
188 188
189 return NULL; 189 return NULL;
190 } 190 }
191 191
192 } // namespace content 192 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698