diff options
author | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-01-20 04:10:52 +0000 |
---|---|---|
committer | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-01-20 04:10:52 +0000 |
commit | 5bf5231373631d2ed940ad9eb03da77132411f57 (patch) | |
tree | ce46ce9f8c4c9b387734adef17de07ca9e306af7 /remoting/protocol/content_description.cc | |
parent | 0bc93ad3a6030cac29eae47feba2704b92b9f15a (diff) | |
download | chromium_src-5bf5231373631d2ed940ad9eb03da77132411f57.zip chromium_src-5bf5231373631d2ed940ad9eb03da77132411f57.tar.gz chromium_src-5bf5231373631d2ed940ad9eb03da77132411f57.tar.bz2 |
Use scoped_ptr<>.Pass() to pass ownership in the remoting protocol code.
Review URL: https://chromiumcodereview.appspot.com/9240033
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@118407 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/protocol/content_description.cc')
-rw-r--r-- | remoting/protocol/content_description.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/remoting/protocol/content_description.cc b/remoting/protocol/content_description.cc index 15583b0..5e157ad 100644 --- a/remoting/protocol/content_description.cc +++ b/remoting/protocol/content_description.cc @@ -146,10 +146,10 @@ bool ParseChannelConfig(const XmlElement* element, bool codec_required, } // namespace ContentDescription::ContentDescription( - const CandidateSessionConfig* candidate_config, - const buzz::XmlElement* authenticator_message) - : candidate_config_(candidate_config), - authenticator_message_(authenticator_message) { + scoped_ptr<CandidateSessionConfig> config, + scoped_ptr<buzz::XmlElement> authenticator_message) + : candidate_config_(config.Pass()), + authenticator_message_(authenticator_message.Pass()) { } ContentDescription::~ContentDescription() { } @@ -247,8 +247,7 @@ ContentDescription* ContentDescription::ParseXml( if (child) authenticator_message.reset(new XmlElement(*child)); - return new ContentDescription( - config.release(), authenticator_message.release()); + return new ContentDescription(config.Pass(), authenticator_message.Pass()); } LOG(ERROR) << "Invalid description: " << element->Str(); return NULL; |