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

Unified Diff: webrtc/base/nethelpers.cc

Issue 2718663005: Replace NULL with nullptr or null in webrtc/base/. (Closed)
Patch Set: Fixing Windows and formatting issues. Created 3 years, 10 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 | « webrtc/base/natsocketfactory.cc ('k') | webrtc/base/network.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/nethelpers.cc
diff --git a/webrtc/base/nethelpers.cc b/webrtc/base/nethelpers.cc
index 7ca654949ce5e1767d17e501c5622e0d2822e25b..6c2ef9c5f6bb28eb5745efaa8eb74050866d8ba2 100644
--- a/webrtc/base/nethelpers.cc
+++ b/webrtc/base/nethelpers.cc
@@ -43,7 +43,7 @@ int ResolveHostname(const std::string& hostname, int family,
return -1;
}
addresses->clear();
- struct addrinfo* result = NULL;
+ struct addrinfo* result = nullptr;
struct addrinfo hints = {0};
hints.ai_family = family;
// |family| here will almost always be AF_UNSPEC, because |family| comes from
@@ -64,7 +64,7 @@ int ResolveHostname(const std::string& hostname, int family,
// https://android.googlesource.com/platform/bionic/+/
// 7e0bfb511e85834d7c6cb9631206b62f82701d60/libc/netbsd/net/getaddrinfo.c#1657
hints.ai_flags = AI_ADDRCONFIG;
- int ret = getaddrinfo(hostname.c_str(), NULL, &hints, &result);
+ int ret = getaddrinfo(hostname.c_str(), nullptr, &hints, &result);
if (ret != 0) {
return ret;
}
@@ -151,7 +151,7 @@ bool HasIPv6Enabled() {
}
DWORD protbuff_size = 4096;
std::unique_ptr<char[]> protocols;
- LPWSAPROTOCOL_INFOW protocol_infos = NULL;
+ LPWSAPROTOCOL_INFOW protocol_infos = nullptr;
int requested_protocols[2] = {AF_INET6, 0};
int err = 0;
« no previous file with comments | « webrtc/base/natsocketfactory.cc ('k') | webrtc/base/network.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698