From cb205a207ce6c2f4e01247e2270e2fe687062a23 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Thu, 4 Jul 2013 00:13:15 +0900 Subject: Use std::unique_ptr for HttpRequest instead of std::shared_ptr --- src/FtpNegotiationCommand.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/FtpNegotiationCommand.cc') diff --git a/src/FtpNegotiationCommand.cc b/src/FtpNegotiationCommand.cc index af0f80e1..ef943859 100644 --- a/src/FtpNegotiationCommand.cc +++ b/src/FtpNegotiationCommand.cc @@ -734,7 +734,7 @@ bool FtpNegotiationCommand::sendTunnelRequest() } } } - std::shared_ptr httpRequest(new HttpRequest()); + auto httpRequest = make_unique(); httpRequest->setUserAgent(getOption()->get(PREF_USER_AGENT)); std::shared_ptr req(new Request()); // Construct fake URI in order to use HttpRequest @@ -749,7 +749,7 @@ bool FtpNegotiationCommand::sendTunnelRequest() } httpRequest->setRequest(req); httpRequest->setProxyRequest(createProxyRequest()); - http_->sendProxyRequest(httpRequest); + http_->sendProxyRequest(std::move(httpRequest)); } else { http_->sendPendingData(); } -- cgit