NP: Disable some logging (#13061)

This commit is contained in:
Ani 2022-12-11 16:49:14 +00:00 committed by GitHub
parent 057f5beac6
commit 0d929a210f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View file

@ -468,7 +468,7 @@ namespace np
return; return;
} }
nph_log.notice("discover_ip_address: Hostname was determined to be %s", hostname.c_str()); // nph_log.notice("discover_ip_address: Hostname was determined to be %s", hostname.c_str());
hostent* host = gethostbyname(hostname.data()); hostent* host = gethostbyname(hostname.data());
if (!host) if (!host)
@ -488,7 +488,7 @@ namespace np
// Set public address to local discovered address for now, may be updated later from RPCN socket // Set public address to local discovered address for now, may be updated later from RPCN socket
public_ip_addr = local_ip_addr; public_ip_addr = local_ip_addr;
nph_log.notice("discover_ip_address: IP was determined to be %s", ip_to_string(local_ip_addr)); // nph_log.notice("discover_ip_address: IP was determined to be %s", ip_to_string(local_ip_addr));
} }
bool np_handler::discover_ether_address() bool np_handler::discover_ether_address()
@ -506,7 +506,7 @@ namespace np
sockaddr_dl* sdp = reinterpret_cast<sockaddr_dl*>(p->ifa_addr); sockaddr_dl* sdp = reinterpret_cast<sockaddr_dl*>(p->ifa_addr);
memcpy(ether_address.data(), sdp->sdl_data + sdp->sdl_nlen, 6); memcpy(ether_address.data(), sdp->sdl_data + sdp->sdl_nlen, 6);
freeifaddrs(ifap); freeifaddrs(ifap);
nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address)); // nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address));
return true; return true;
} }
} }
@ -523,7 +523,7 @@ namespace np
{ {
PIP_ADAPTER_INFO info = reinterpret_cast<PIP_ADAPTER_INFO>(adapter_infos.data()); PIP_ADAPTER_INFO info = reinterpret_cast<PIP_ADAPTER_INFO>(adapter_infos.data());
memcpy(ether_address.data(), info[0].Address, 6); memcpy(ether_address.data(), info[0].Address, 6);
nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address)); // nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address));
return true; return true;
} }
#else #else
@ -563,7 +563,7 @@ namespace np
if (success) if (success)
{ {
memcpy(ether_address.data(), ifr.ifr_hwaddr.sa_data, 6); memcpy(ether_address.data(), ifr.ifr_hwaddr.sa_data, 6);
nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address)); // nph_log.notice("Determined Ethernet address to be %s", ether_to_string(ether_address));
return true; return true;
} }

View file

@ -732,7 +732,7 @@ namespace rpcn
} }
update_local_addr(client_addr.sin_addr.s_addr); update_local_addr(client_addr.sin_addr.s_addr);
rpcn_log.notice("Updated local address to %s", np::ip_to_string(std::bit_cast<u32, be_t<u32>>(local_addr_sig.load()))); // rpcn_log.notice("Updated local address to %s", np::ip_to_string(std::bit_cast<u32, be_t<u32>>(local_addr_sig.load())));
if (wolfSSL_set_fd(read_wssl, sockfd) != WOLFSSL_SUCCESS) if (wolfSSL_set_fd(read_wssl, sockfd) != WOLFSSL_SUCCESS)
{ {