Adapt to changes of Chrome 51 API changes
This commit is contained in:
parent
e7be3d0ef9
commit
851ef398fb
39 changed files with 157 additions and 196 deletions
|
@ -45,11 +45,11 @@ class TCPServerSocketFactory
|
|||
|
||||
private:
|
||||
// content::DevToolsHttpHandler::ServerSocketFactory.
|
||||
scoped_ptr<net::ServerSocket> CreateForHttpServer() override {
|
||||
scoped_ptr<net::ServerSocket> socket(
|
||||
std::unique_ptr<net::ServerSocket> CreateForHttpServer() override {
|
||||
std::unique_ptr<net::ServerSocket> socket(
|
||||
new net::TCPServerSocket(nullptr, net::NetLog::Source()));
|
||||
if (socket->ListenWithAddressAndPort(address_, port_, 10) != net::OK)
|
||||
return scoped_ptr<net::ServerSocket>();
|
||||
return std::unique_ptr<net::ServerSocket>();
|
||||
|
||||
return socket;
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ class TCPServerSocketFactory
|
|||
DISALLOW_COPY_AND_ASSIGN(TCPServerSocketFactory);
|
||||
};
|
||||
|
||||
scoped_ptr<devtools_http_handler::DevToolsHttpHandler::ServerSocketFactory>
|
||||
std::unique_ptr<devtools_http_handler::DevToolsHttpHandler::ServerSocketFactory>
|
||||
CreateSocketFactory() {
|
||||
auto& command_line = *base::CommandLine::ForCurrentProcess();
|
||||
// See if the user specified a port on the command line (useful for
|
||||
|
@ -77,7 +77,7 @@ CreateSocketFactory() {
|
|||
DLOG(WARNING) << "Invalid http debugger port number " << temp_port;
|
||||
}
|
||||
}
|
||||
return scoped_ptr<
|
||||
return std::unique_ptr<
|
||||
devtools_http_handler::DevToolsHttpHandler::ServerSocketFactory>(
|
||||
new TCPServerSocketFactory("127.0.0.1", port));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue