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

Side by Side Diff: remoting/client/plugin/pepper_packet_socket_factory.cc

Issue 1864213002: Convert //remoting to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Mac IWYU 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) 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 "remoting/client/plugin/pepper_packet_socket_factory.h" 5 #include "remoting/client/plugin/pepper_packet_socket_factory.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 : pp_instance_(instance) { 407 : pp_instance_(instance) {
408 } 408 }
409 409
410 PepperPacketSocketFactory::~PepperPacketSocketFactory() { 410 PepperPacketSocketFactory::~PepperPacketSocketFactory() {
411 } 411 }
412 412
413 rtc::AsyncPacketSocket* PepperPacketSocketFactory::CreateUdpSocket( 413 rtc::AsyncPacketSocket* PepperPacketSocketFactory::CreateUdpSocket(
414 const rtc::SocketAddress& local_address, 414 const rtc::SocketAddress& local_address,
415 uint16_t min_port, 415 uint16_t min_port,
416 uint16_t max_port) { 416 uint16_t max_port) {
417 scoped_ptr<UdpPacketSocket> result(new UdpPacketSocket(pp_instance_)); 417 std::unique_ptr<UdpPacketSocket> result(new UdpPacketSocket(pp_instance_));
418 if (!result->Init(local_address, min_port, max_port)) 418 if (!result->Init(local_address, min_port, max_port))
419 return nullptr; 419 return nullptr;
420 return result.release(); 420 return result.release();
421 } 421 }
422 422
423 rtc::AsyncPacketSocket* PepperPacketSocketFactory::CreateServerTcpSocket( 423 rtc::AsyncPacketSocket* PepperPacketSocketFactory::CreateServerTcpSocket(
424 const rtc::SocketAddress& local_address, 424 const rtc::SocketAddress& local_address,
425 uint16_t min_port, 425 uint16_t min_port,
426 uint16_t max_port, 426 uint16_t max_port,
427 int opts) { 427 int opts) {
(...skipping 12 matching lines...) Expand all
440 NOTREACHED(); 440 NOTREACHED();
441 return nullptr; 441 return nullptr;
442 } 442 }
443 443
444 rtc::AsyncResolverInterface* 444 rtc::AsyncResolverInterface*
445 PepperPacketSocketFactory::CreateAsyncResolver() { 445 PepperPacketSocketFactory::CreateAsyncResolver() {
446 return new PepperAddressResolver(pp_instance_); 446 return new PepperAddressResolver(pp_instance_);
447 } 447 }
448 448
449 } // namespace remoting 449 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/client/plugin/pepper_mouse_locker.h ('k') | remoting/client/plugin/pepper_port_allocator_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698