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

Unified Diff: ipc/ipc_channel_common.cc

Issue 310293002: Make IPC::Channel polymorphic (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Another attempt to fix build breakage Created 6 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 | « ipc/ipc_channel.h ('k') | ipc/ipc_channel_nacl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ipc/ipc_channel_common.cc
diff --git a/ipc/ipc_channel_common.cc b/ipc/ipc_channel_common.cc
index c5ceba3e5714fb861eea3774fcdc16a26d97a838..d7347cc7a1b7611d940f7170ddbb83d217fc322e 100644
--- a/ipc/ipc_channel_common.cc
+++ b/ipc/ipc_channel_common.cc
@@ -7,49 +7,41 @@
namespace IPC {
// static
-scoped_ptr<Channel> Channel::CreateByModeForProxy(
- const IPC::ChannelHandle &channel_handle, Mode mode, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, mode, listener));
-}
-
-// static
scoped_ptr<Channel> Channel::CreateClient(
const IPC::ChannelHandle &channel_handle, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, Channel::MODE_CLIENT, listener));
+ return Channel::Create(channel_handle, Channel::MODE_CLIENT, listener);
}
// static
scoped_ptr<Channel> Channel::CreateNamedServer(
const IPC::ChannelHandle &channel_handle, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, Channel::MODE_NAMED_SERVER, listener));
+ return Channel::Create(channel_handle, Channel::MODE_NAMED_SERVER, listener);
}
// static
scoped_ptr<Channel> Channel::CreateNamedClient(
const IPC::ChannelHandle &channel_handle, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, Channel::MODE_NAMED_CLIENT, listener));
+ return Channel::Create(channel_handle, Channel::MODE_NAMED_CLIENT, listener);
}
#if defined(OS_POSIX)
// static
scoped_ptr<Channel> Channel::CreateOpenNamedServer(
const IPC::ChannelHandle &channel_handle, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, Channel::MODE_OPEN_NAMED_SERVER, listener));
+ return Channel::Create(channel_handle,
+ Channel::MODE_OPEN_NAMED_SERVER,
+ listener);
}
#endif
// static
scoped_ptr<Channel> Channel::CreateServer(
const IPC::ChannelHandle &channel_handle, Listener* listener) {
- return make_scoped_ptr(
- new Channel(channel_handle, Channel::MODE_SERVER, listener));
+ return Channel::Create(channel_handle, Channel::MODE_SERVER, listener);
}
+Channel::~Channel() {
+}
} // namespace IPC
« no previous file with comments | « ipc/ipc_channel.h ('k') | ipc/ipc_channel_nacl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698