Index: ipc/ipc_channel_posix_unittest.cc |
diff --git a/ipc/ipc_channel_posix_unittest.cc b/ipc/ipc_channel_posix_unittest.cc |
index 6f37ae62bc55fe50b62033c65868c56d12e3beba..61c21d36c5166ab68282a5ee0ed756c471a9fc03 100644 |
--- a/ipc/ipc_channel_posix_unittest.cc |
+++ b/ipc/ipc_channel_posix_unittest.cc |
@@ -107,8 +107,13 @@ private: |
scoped_ptr<MessageLoopForIO> message_loop_; |
}; |
+#if defined(OS_ANDROID) |
+const char IPCChannelPosixTest::kConnectionSocketTestName[] = |
+ "/data/local/chrome_IPCChannelPosixTest__ConnectionSocket"; |
+#else |
const char IPCChannelPosixTest::kConnectionSocketTestName[] = |
"/var/tmp/chrome_IPCChannelPosixTest__ConnectionSocket"; |
+#endif |
void IPCChannelPosixTest::SetUp() { |
MultiProcessTest::SetUp(); |
@@ -177,8 +182,14 @@ void IPCChannelPosixTest::SpinRunLoop(int milliseconds) { |
} |
TEST_F(IPCChannelPosixTest, BasicListen) { |
+ |
+#if defined(OS_ANDROID) |
+ const char* kChannelName = "/data/local/IPCChannelPosixTest_BasicListen"; |
+#else |
+ const char* kChannelName = "/var/tmp/IPCChannelPosixTest_BasicListen"; |
+#endif |
// Test creating a socket that is listening. |
- IPC::ChannelHandle handle("/var/tmp/IPCChannelPosixTest_BasicListen"); |
+ IPC::ChannelHandle handle(kChannelName); |
SetUpSocket(&handle, IPC::Channel::MODE_NAMED_SERVER); |
unlink(handle.name.c_str()); |
IPC::Channel channel(handle, IPC::Channel::MODE_NAMED_SERVER, NULL); |
@@ -404,4 +415,3 @@ MULTIPROCESS_TEST_MAIN(IPCChannelPosixFailConnectionProc) { |
} |
return 0; |
} |
- |