diff options
author | iphydf <iphydf@users.noreply.github.com> | 2018-01-28 21:30:39 +0000 |
---|---|---|
committer | iphydf <iphydf@users.noreply.github.com> | 2018-01-30 23:35:50 +0000 |
commit | 92ffad1a72bc8c422426d52ac408bd71242dd047 (patch) | |
tree | f592f353068dd2043525dd2cc04d6124a4ed4bc4 /toxcore/LAN_discovery.c | |
parent | 623e9ac331df7323660e21c8a2226523a5ee713b (diff) |
Use nullptr as NULL pointer constant instead of NULL or 0.
This changes only code, no string literals or comments.
Diffstat (limited to 'toxcore/LAN_discovery.c')
-rw-r--r-- | toxcore/LAN_discovery.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/toxcore/LAN_discovery.c b/toxcore/LAN_discovery.c index c0724ad9..742b91ab 100644 --- a/toxcore/LAN_discovery.c +++ b/toxcore/LAN_discovery.c | |||
@@ -52,7 +52,7 @@ static void fetch_broadcast_info(uint16_t port) | |||
52 | IP_ADAPTER_INFO *pAdapterInfo = (IP_ADAPTER_INFO *)malloc(sizeof(IP_ADAPTER_INFO)); | 52 | IP_ADAPTER_INFO *pAdapterInfo = (IP_ADAPTER_INFO *)malloc(sizeof(IP_ADAPTER_INFO)); |
53 | unsigned long ulOutBufLen = sizeof(IP_ADAPTER_INFO); | 53 | unsigned long ulOutBufLen = sizeof(IP_ADAPTER_INFO); |
54 | 54 | ||
55 | if (pAdapterInfo == NULL) { | 55 | if (pAdapterInfo == nullptr) { |
56 | return; | 56 | return; |
57 | } | 57 | } |
58 | 58 | ||
@@ -60,7 +60,7 @@ static void fetch_broadcast_info(uint16_t port) | |||
60 | free(pAdapterInfo); | 60 | free(pAdapterInfo); |
61 | pAdapterInfo = (IP_ADAPTER_INFO *)malloc(ulOutBufLen); | 61 | pAdapterInfo = (IP_ADAPTER_INFO *)malloc(ulOutBufLen); |
62 | 62 | ||
63 | if (pAdapterInfo == NULL) { | 63 | if (pAdapterInfo == nullptr) { |
64 | return; | 64 | return; |
65 | } | 65 | } |
66 | } | 66 | } |
@@ -405,5 +405,5 @@ void lan_discovery_init(DHT *dht) | |||
405 | 405 | ||
406 | void lan_discovery_kill(DHT *dht) | 406 | void lan_discovery_kill(DHT *dht) |
407 | { | 407 | { |
408 | networking_registerhandler(dht_get_net(dht), NET_PACKET_LAN_DISCOVERY, NULL, NULL); | 408 | networking_registerhandler(dht_get_net(dht), NET_PACKET_LAN_DISCOVERY, nullptr, nullptr); |
409 | } | 409 | } |