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

Unified Diff: remoting/protocol/video_writer.cc

Issue 10556020: Cleaned up the reader and writer create methods to return scoped_ptr. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Removed unnecessary code Created 8 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/protocol/video_writer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/video_writer.cc
diff --git a/remoting/protocol/video_writer.cc b/remoting/protocol/video_writer.cc
index 99da94771a8dc836bad8ce973bdc7ce3d23c2f7a..04f03f3fd1c907650b69d1e3e50dbb5de03860f1 100644
--- a/remoting/protocol/video_writer.cc
+++ b/remoting/protocol/video_writer.cc
@@ -13,12 +13,12 @@ namespace protocol {
VideoWriter::~VideoWriter() { }
// static
-VideoWriter* VideoWriter::Create(const SessionConfig& config) {
+scoped_ptr<VideoWriter> VideoWriter::Create(const SessionConfig& config) {
const ChannelConfig& video_config = config.video_config();
if (video_config.transport == ChannelConfig::TRANSPORT_STREAM) {
- return new ProtobufVideoWriter();
+ return scoped_ptr<VideoWriter>(new ProtobufVideoWriter());
}
- return NULL;
+ return scoped_ptr<VideoWriter>(NULL);
}
} // namespace protocol
« no previous file with comments | « remoting/protocol/video_writer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698