Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(143)

Side by Side Diff: remoting/protocol/content_description.cc

Issue 810133003: replace NULL->nullptr in src/remoting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « remoting/protocol/connection_to_host.cc ('k') | remoting/protocol/datagram_channel_factory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "remoting/protocol/content_description.h" 5 #include "remoting/protocol/content_description.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "remoting/base/constants.h" 9 #include "remoting/base/constants.h"
10 #include "remoting/protocol/authenticator.h" 10 #include "remoting/protocol/authenticator.h"
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 scoped_ptr<CandidateSessionConfig> config, 116 scoped_ptr<CandidateSessionConfig> config,
117 scoped_ptr<buzz::XmlElement> authenticator_message) 117 scoped_ptr<buzz::XmlElement> authenticator_message)
118 : candidate_config_(config.Pass()), 118 : candidate_config_(config.Pass()),
119 authenticator_message_(authenticator_message.Pass()) { 119 authenticator_message_(authenticator_message.Pass()) {
120 } 120 }
121 121
122 ContentDescription::~ContentDescription() { } 122 ContentDescription::~ContentDescription() { }
123 123
124 ContentDescription* ContentDescription::Copy() const { 124 ContentDescription* ContentDescription::Copy() const {
125 if (!candidate_config_.get() || !authenticator_message_.get()) { 125 if (!candidate_config_.get() || !authenticator_message_.get()) {
126 return NULL; 126 return nullptr;
127 } 127 }
128 scoped_ptr<XmlElement> message(new XmlElement(*authenticator_message_)); 128 scoped_ptr<XmlElement> message(new XmlElement(*authenticator_message_));
129 return new ContentDescription(candidate_config_->Clone(), message.Pass()); 129 return new ContentDescription(candidate_config_->Clone(), message.Pass());
130 } 130 }
131 131
132 // ToXml() creates content description for chromoting session. The 132 // ToXml() creates content description for chromoting session. The
133 // description looks as follows: 133 // description looks as follows:
134 // <description xmlns="google:remoting"> 134 // <description xmlns="google:remoting">
135 // <control transport="stream" version="1" /> 135 // <control transport="stream" version="1" />
136 // <event transport="datagram" version="1" /> 136 // <event transport="datagram" version="1" />
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 const XmlElement* child = Authenticator::FindAuthenticatorMessage(element); 233 const XmlElement* child = Authenticator::FindAuthenticatorMessage(element);
234 if (child) 234 if (child)
235 authenticator_message.reset(new XmlElement(*child)); 235 authenticator_message.reset(new XmlElement(*child));
236 236
237 return make_scoped_ptr( 237 return make_scoped_ptr(
238 new ContentDescription(config.Pass(), authenticator_message.Pass())); 238 new ContentDescription(config.Pass(), authenticator_message.Pass()));
239 } 239 }
240 240
241 } // namespace protocol 241 } // namespace protocol
242 } // namespace remoting 242 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/connection_to_host.cc ('k') | remoting/protocol/datagram_channel_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698