From 07d270c87e6f9184aea4ca17eb26e466712e8db2 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sat, 22 Jun 2013 01:10:38 +0900 Subject: Require -std=c++11 and use std::shared_ptr instead of SharedHandle --- src/AbstractProxyRequestCommand.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/AbstractProxyRequestCommand.cc') diff --git a/src/AbstractProxyRequestCommand.cc b/src/AbstractProxyRequestCommand.cc index d24475b3..4d511883 100644 --- a/src/AbstractProxyRequestCommand.cc +++ b/src/AbstractProxyRequestCommand.cc @@ -51,18 +51,18 @@ namespace aria2 { AbstractProxyRequestCommand::AbstractProxyRequestCommand (cuid_t cuid, - const SharedHandle& req, - const SharedHandle& fileEntry, + const std::shared_ptr& req, + const std::shared_ptr& fileEntry, RequestGroup* requestGroup, DownloadEngine* e, - const SharedHandle& proxyRequest, - const SharedHandle& s) + const std::shared_ptr& proxyRequest, + const std::shared_ptr& s) : AbstractCommand(cuid, req, fileEntry, requestGroup, e, s), proxyRequest_(proxyRequest), httpConnection_ (new HttpConnection - (cuid, s, SharedHandle(new SocketRecvBuffer(s)))) + (cuid, s, std::shared_ptr(new SocketRecvBuffer(s)))) { setTimeout(getOption()->getAsInt(PREF_CONNECT_TIMEOUT)); disableReadCheckSocket(); @@ -74,7 +74,7 @@ AbstractProxyRequestCommand::~AbstractProxyRequestCommand() {} bool AbstractProxyRequestCommand::executeInternal() { //socket->setBlockingMode(); if(httpConnection_->sendBufferIsEmpty()) { - SharedHandle httpRequest(new HttpRequest()); + std::shared_ptr httpRequest(new HttpRequest()); httpRequest->setUserAgent(getOption()->get(PREF_USER_AGENT)); httpRequest->setRequest(getRequest()); httpRequest->setProxyRequest(proxyRequest_); -- cgit