From 57f1902ee1fd24e2fa94a5e5c0ee357335366d7d Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Thu, 4 Jul 2013 00:39:11 +0900 Subject: Use std::unique_ptr for StreamFilter instead of std::shared_ptr --- src/HttpSkipResponseCommand.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/HttpSkipResponseCommand.cc') diff --git a/src/HttpSkipResponseCommand.cc b/src/HttpSkipResponseCommand.cc index 6cfa9706..f8641101 100644 --- a/src/HttpSkipResponseCommand.cc +++ b/src/HttpSkipResponseCommand.cc @@ -87,13 +87,13 @@ HttpSkipResponseCommand::HttpSkipResponseCommand HttpSkipResponseCommand::~HttpSkipResponseCommand() {} void HttpSkipResponseCommand::installStreamFilter -(const std::shared_ptr& streamFilter) +(std::unique_ptr streamFilter) { if(!streamFilter) { return; } - streamFilter->installDelegate(streamFilter_); - streamFilter_ = streamFilter; + streamFilter->installDelegate(std::move(streamFilter_)); + streamFilter_ = std::move(streamFilter); const std::string& name = streamFilter_->getName(); sinkFilterOnly_ = util::endsWith(name, SinkStreamFilter::NAME); } -- cgit