Index: ipc/ipc_channel_posix_unittest.cc |
diff --git a/ipc/ipc_channel_posix_unittest.cc b/ipc/ipc_channel_posix_unittest.cc |
index aa545402f4b795fccba18b589240354a0d255c2c..9209d2c091afde5b493edd9b2c2285c36c6ba7e5 100644 |
--- a/ipc/ipc_channel_posix_unittest.cc |
+++ b/ipc/ipc_channel_posix_unittest.cc |
@@ -201,8 +201,8 @@ TEST_F(IPCChannelPosixTest, BasicListen) { |
IPC::ChannelHandle handle(kChannelName); |
SetUpSocket(&handle, IPC::Channel::MODE_NAMED_SERVER); |
unlink(handle.name.c_str()); |
- scoped_ptr<IPC::ChannelPosix> channel( |
- new IPC::ChannelPosix(handle, IPC::Channel::MODE_NAMED_SERVER, NULL)); |
+ scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
+ handle, IPC::Channel::MODE_NAMED_SERVER, NULL, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_TRUE(channel->AcceptsConnections()); |
ASSERT_FALSE(channel->HasAcceptedConnection()); |
@@ -220,8 +220,8 @@ TEST_F(IPCChannelPosixTest, BasicConnected) { |
base::FileDescriptor fd(pipe_fds[0], false); |
IPC::ChannelHandle handle(socket_name, fd); |
- scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- handle, IPC::Channel::MODE_SERVER, NULL)); |
+ scoped_ptr<IPC::ChannelPosix> channel( |
+ new IPC::ChannelPosix(handle, IPC::Channel::MODE_SERVER, NULL, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_FALSE(channel->AcceptsConnections()); |
channel->Close(); |
@@ -230,7 +230,7 @@ TEST_F(IPCChannelPosixTest, BasicConnected) { |
// Make sure that we can use the socket that is created for us by |
// a standard channel. |
scoped_ptr<IPC::ChannelPosix> channel2(new IPC::ChannelPosix( |
- socket_name, IPC::Channel::MODE_SERVER, NULL)); |
+ socket_name, IPC::Channel::MODE_SERVER, NULL, nullptr)); |
ASSERT_TRUE(channel2->Connect()); |
ASSERT_FALSE(channel2->AcceptsConnections()); |
} |
@@ -243,11 +243,11 @@ TEST_F(IPCChannelPosixTest, SendHangTest) { |
IPCChannelPosixTestListener in_listener(true); |
IPC::ChannelHandle in_handle("IN"); |
scoped_ptr<IPC::ChannelPosix> in_chan(new IPC::ChannelPosix( |
- in_handle, IPC::Channel::MODE_SERVER, &in_listener)); |
+ in_handle, IPC::Channel::MODE_SERVER, &in_listener, nullptr)); |
IPC::ChannelHandle out_handle( |
"OUT", base::FileDescriptor(in_chan->TakeClientFileDescriptor())); |
scoped_ptr<IPC::ChannelPosix> out_chan(new IPC::ChannelPosix( |
- out_handle, IPC::Channel::MODE_CLIENT, &out_listener)); |
+ out_handle, IPC::Channel::MODE_CLIENT, &out_listener, nullptr)); |
ASSERT_TRUE(in_chan->Connect()); |
ASSERT_TRUE(out_chan->Connect()); |
in_chan->Close(); // simulate remote process dying at an unfortunate time. |
@@ -268,11 +268,11 @@ TEST_F(IPCChannelPosixTest, AcceptHangTest) { |
IPCChannelPosixTestListener in_listener(true); |
IPC::ChannelHandle in_handle("IN"); |
scoped_ptr<IPC::ChannelPosix> in_chan(new IPC::ChannelPosix( |
- in_handle, IPC::Channel::MODE_SERVER, &in_listener)); |
+ in_handle, IPC::Channel::MODE_SERVER, &in_listener, nullptr)); |
IPC::ChannelHandle out_handle( |
"OUT", base::FileDescriptor(in_chan->TakeClientFileDescriptor())); |
scoped_ptr<IPC::ChannelPosix> out_chan(new IPC::ChannelPosix( |
- out_handle, IPC::Channel::MODE_CLIENT, &out_listener)); |
+ out_handle, IPC::Channel::MODE_CLIENT, &out_listener, nullptr)); |
ASSERT_TRUE(in_chan->Connect()); |
in_chan->Close(); // simulate remote process dying at an unfortunate time. |
ASSERT_FALSE(out_chan->Connect()); |
@@ -286,7 +286,7 @@ TEST_F(IPCChannelPosixTest, AdvancedConnected) { |
IPC::ChannelHandle chan_handle(GetConnectionSocketName()); |
SetUpSocket(&chan_handle, IPC::Channel::MODE_NAMED_SERVER); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener)); |
+ chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_TRUE(channel->AcceptsConnections()); |
ASSERT_FALSE(channel->HasAcceptedConnection()); |
@@ -317,7 +317,7 @@ TEST_F(IPCChannelPosixTest, ResetState) { |
IPC::ChannelHandle chan_handle(GetConnectionSocketName()); |
SetUpSocket(&chan_handle, IPC::Channel::MODE_NAMED_SERVER); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener)); |
+ chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_TRUE(channel->AcceptsConnections()); |
ASSERT_FALSE(channel->HasAcceptedConnection()); |
@@ -353,7 +353,7 @@ TEST_F(IPCChannelPosixTest, BadChannelName) { |
// Test empty name |
IPC::ChannelHandle handle(""); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- handle, IPC::Channel::MODE_NAMED_SERVER, NULL)); |
+ handle, IPC::Channel::MODE_NAMED_SERVER, NULL, nullptr)); |
ASSERT_FALSE(channel->Connect()); |
// Test name that is too long. |
@@ -367,7 +367,7 @@ TEST_F(IPCChannelPosixTest, BadChannelName) { |
EXPECT_GE(strlen(kTooLongName), IPC::kMaxSocketNameLength); |
IPC::ChannelHandle handle2(kTooLongName); |
scoped_ptr<IPC::ChannelPosix> channel2(new IPC::ChannelPosix( |
- handle2, IPC::Channel::MODE_NAMED_SERVER, NULL)); |
+ handle2, IPC::Channel::MODE_NAMED_SERVER, NULL, nullptr)); |
EXPECT_FALSE(channel2->Connect()); |
} |
@@ -378,7 +378,7 @@ TEST_F(IPCChannelPosixTest, MultiConnection) { |
IPC::ChannelHandle chan_handle(GetConnectionSocketName()); |
SetUpSocket(&chan_handle, IPC::Channel::MODE_NAMED_SERVER); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener)); |
+ chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_TRUE(channel->AcceptsConnections()); |
ASSERT_FALSE(channel->HasAcceptedConnection()); |
@@ -414,9 +414,9 @@ TEST_F(IPCChannelPosixTest, DoubleServer) { |
IPCChannelPosixTestListener listener2(false); |
IPC::ChannelHandle chan_handle(GetConnectionSocketName()); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_SERVER, &listener)); |
+ chan_handle, IPC::Channel::MODE_SERVER, &listener, nullptr)); |
scoped_ptr<IPC::ChannelPosix> channel2(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_SERVER, &listener2)); |
+ chan_handle, IPC::Channel::MODE_SERVER, &listener2, nullptr)); |
ASSERT_TRUE(channel->Connect()); |
ASSERT_FALSE(channel2->Connect()); |
} |
@@ -426,7 +426,7 @@ TEST_F(IPCChannelPosixTest, BadMode) { |
IPCChannelPosixTestListener listener(false); |
IPC::ChannelHandle chan_handle(GetConnectionSocketName()); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_NONE, &listener)); |
+ chan_handle, IPC::Channel::MODE_NONE, &listener, nullptr)); |
ASSERT_FALSE(channel->Connect()); |
} |
@@ -438,7 +438,7 @@ TEST_F(IPCChannelPosixTest, IsNamedServerInitialized) { |
ASSERT_FALSE(IPC::Channel::IsNamedServerInitialized( |
connection_socket_name)); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener)); |
+ chan_handle, IPC::Channel::MODE_NAMED_SERVER, &listener, nullptr)); |
ASSERT_TRUE(IPC::Channel::IsNamedServerInitialized( |
connection_socket_name)); |
channel->Close(); |
@@ -454,7 +454,7 @@ MULTIPROCESS_TEST_MAIN(IPCChannelPosixTestConnectionProc) { |
IPC::ChannelHandle handle(IPCChannelPosixTest::GetConnectionSocketName()); |
IPCChannelPosixTest::SetUpSocket(&handle, IPC::Channel::MODE_NAMED_CLIENT); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- handle, IPC::Channel::MODE_NAMED_CLIENT, &listener)); |
+ handle, IPC::Channel::MODE_NAMED_CLIENT, &listener, nullptr)); |
EXPECT_TRUE(channel->Connect()); |
IPCChannelPosixTest::SpinRunLoop(TestTimeouts::action_max_timeout()); |
EXPECT_EQ(IPCChannelPosixTestListener::MESSAGE_RECEIVED, listener.status()); |
@@ -468,7 +468,7 @@ MULTIPROCESS_TEST_MAIN(IPCChannelPosixFailConnectionProc) { |
IPC::ChannelHandle handle(IPCChannelPosixTest::GetConnectionSocketName()); |
IPCChannelPosixTest::SetUpSocket(&handle, IPC::Channel::MODE_NAMED_CLIENT); |
scoped_ptr<IPC::ChannelPosix> channel(new IPC::ChannelPosix( |
- handle, IPC::Channel::MODE_NAMED_CLIENT, &listener)); |
+ handle, IPC::Channel::MODE_NAMED_CLIENT, &listener, nullptr)); |
// In this case connect may succeed or fail depending on if the packet |
// actually gets sent at sendmsg. Since we never delay on send, we may not |