Up the warnings in ipc (take 2)
- add chromium_code:1 to the GYP file
- Fix some unittest compares of literal 0 to apis that return size_t
- initializer order match declared order
- type_id is a uint32, so fix up comparison warnings by using the right type in the test code.
- duplicate a type cast used in the ipc headers into the ipc impl to make windows happy.
- msvc warns about getenv, avoid it.
BUG=none
TEST=everything still builds/works
Review URL: http://codereview.chromium.org/2821028
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53468 0039d316-1c4b-4281-b951-d872f2087c98
CrOS-Libchrome-Original-Commit: 7ee1a44c27384650612290a18ccbe736e0e4b955
diff --git a/ipc/ipc_channel_posix.cc b/ipc/ipc_channel_posix.cc
index 6e8e264..3f910cf 100644
--- a/ipc/ipc_channel_posix.cc
+++ b/ipc/ipc_channel_posix.cc
@@ -699,7 +699,7 @@
// On non-Mac, the Hello message from the client to the server
// also contains the fd_pipe_, which will be used for all
// subsequent file descriptor passing.
- DCHECK_EQ(m.file_descriptor_set()->size(), 1);
+ DCHECK_EQ(m.file_descriptor_set()->size(), 1U);
base::FileDescriptor descriptor;
if (!m.ReadFileDescriptor(&iter, &descriptor)) {
NOTREACHED();
@@ -777,7 +777,7 @@
NOTREACHED();
}
msg = hello.get();
- DCHECK_EQ(msg->file_descriptor_set()->size(), 1);
+ DCHECK_EQ(msg->file_descriptor_set()->size(), 1U);
}
#endif
@@ -853,7 +853,7 @@
if (mode_ != MODE_SERVER && !uses_fifo_ &&
msg->routing_id() == MSG_ROUTING_NONE &&
msg->type() == HELLO_MESSAGE_TYPE) {
- DCHECK_EQ(msg->file_descriptor_set()->size(), 1);
+ DCHECK_EQ(msg->file_descriptor_set()->size(), 1U);
}
if (!uses_fifo_ && !msgh.msg_controllen) {
bytes_written = HANDLE_EINTR(write(pipe_, out_bytes, amt_to_write));