summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordcheng <dcheng@chromium.org>2015-07-02 15:30:43 -0700
committerCommit bot <commit-bot@chromium.org>2015-07-02 22:31:26 +0000
commite4e094f274a21a97909fe3a11e79b4d48eabd7c4 (patch)
tree6a66bca77b373d2c4dab35229be9c91d203c3fd0
parent74d18728f27bd9bcbf237167cf1d00e394b90860 (diff)
downloadchromium_src-e4e094f274a21a97909fe3a11e79b4d48eabd7c4.zip
chromium_src-e4e094f274a21a97909fe3a11e79b4d48eabd7c4.tar.gz
chromium_src-e4e094f274a21a97909fe3a11e79b4d48eabd7c4.tar.bz2
Fix some clang warnings with -Wmissing-braces in net.
Clang warns if there are missing braces around a subobject initializer. The most common idiom that triggers this is: STRUCT s = {0}; if the first field of STRUCT is itself a struct. This can be more simply written as: STRUCT s = {}; which also prevents the warning from firing. BUG=505297 Review URL: https://codereview.chromium.org/1217403002 Cr-Commit-Position: refs/heads/master@{#337261}
-rw-r--r--net/base/network_interfaces_unittest.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/base/network_interfaces_unittest.cc b/net/base/network_interfaces_unittest.cc
index ed821cf..06ffb07 100644
--- a/net/base/network_interfaces_unittest.cc
+++ b/net/base/network_interfaces_unittest.cc
@@ -488,9 +488,9 @@ TEST(NetUtilTest, GetNetworkListTrimming) {
NetworkInterfaceList results;
sockaddr_storage addresses[2];
- IP_ADAPTER_ADDRESSES adapter_address = {0};
- IP_ADAPTER_UNICAST_ADDRESS address = {0};
- IP_ADAPTER_PREFIX adapter_prefix = {0};
+ IP_ADAPTER_ADDRESSES adapter_address = {};
+ IP_ADAPTER_UNICAST_ADDRESS address = {};
+ IP_ADAPTER_PREFIX adapter_prefix = {};
adapter_address.FirstUnicastAddress = &address;
adapter_address.FirstPrefix = &adapter_prefix;