misc: unify terminology
8+3 filename → 8.3 filename
be ware → beware
{cannot, can not, can't, could not, couldn't} → unable to
familly → family
file name → filename
informations → information
plateform → platform
trial → attempt
trying to → attempting to
{web-server, webserver} → Web server
Change-Id: I33b1a0091b5af4f0f055bd4c21b2a05a39adbc50
GitLab: https://git.jami.net/savoirfairelinux/jami-client-qt/issues/1730
diff --git a/src/connectionmanager.cpp b/src/connectionmanager.cpp
index da5897e..652a105 100644
--- a/src/connectionmanager.cpp
+++ b/src/connectionmanager.cpp
@@ -949,7 +949,7 @@
connType, ok] {
auto sthis = w.lock();
if (!ok && sthis && sthis->config_->logger)
- sthis->config_->logger->error("[device {}] Cannot initialize ICE session.", devicePk->getLongId());
+ sthis->config_->logger->error("[device {}] Unable to initialize ICE session.", devicePk->getLongId());
if (!sthis || !ok) {
eraseInfo();
return;
@@ -997,7 +997,7 @@
info->ice_ = sthis->config_->factory->createUTransport("");
if (!info->ice_) {
if (sthis->config_->logger)
- sthis->config_->logger->error("[device {}] Cannot initialize ICE session.", deviceId);
+ sthis->config_->logger->error("[device {}] Unable to initialize ICE session.", deviceId);
eraseInfo();
return;
}
@@ -1027,7 +1027,7 @@
auto channelSock = sock->addChannel(name);
if (!channelSock) {
if (config_->logger)
- config_->logger->error("sendChannelRequest failed - cannot create channel");
+ config_->logger->error("sendChannelRequest failed - unable to create channel");
if (auto info = dinfow.lock())
info->executePendingOperations(vid, nullptr);
return;
@@ -1088,7 +1088,7 @@
req.id));
} else {
if (config_->logger)
- config_->logger->warn("[device {}] Respond received, but cannot find request", device);
+ config_->logger->warn("[device {}] Response received, but unable to find request", device);
}
}
@@ -1397,7 +1397,7 @@
return;
if (!ok) {
if (shared->config_->logger)
- shared->config_->logger->error("[device {}] Cannot initialize ICE session.", req.owner->getLongId());
+ shared->config_->logger->error("[device {}] Unable to initialize ICE session.", req.owner->getLongId());
dht::ThreadPool::io().run([eraseInfo = std::move(eraseInfo)] { eraseInfo(); });
return;
}
@@ -1442,7 +1442,7 @@
info->ice_ = shared->config_->factory->createUTransport("");
if (not info->ice_) {
if (shared->config_->logger)
- shared->config_->logger->error("[device {}] Cannot initialize ICE session", deviceId);
+ shared->config_->logger->error("[device {}] Unable to initialize ICE session", deviceId);
eraseInfo();
return;
}
@@ -1663,7 +1663,7 @@
while (top_issuer->issuer)
top_issuer = top_issuer->issuer;
- // Device certificate can't be self-signed
+ // Unable to self-signed device certificate
if (top_issuer == crt) {
if (logger)
logger->warn("Found invalid (self-signed) peer device: {}", crt->getLongId());
diff --git a/src/fileutils.cpp b/src/fileutils.cpp
index 9e23527..335da58 100644
--- a/src/fileutils.cpp
+++ b/src/fileutils.cpp
@@ -124,7 +124,7 @@
try {
std::filesystem::create_symlink(target, linkFile);
} catch (const std::exception& e) {
- //JAMI_ERR("Couldn't create soft link: %s", e.what());
+ //JAMI_ERR("Unable to create soft link: %s", e.what());
return false;
}
return true;
@@ -136,7 +136,7 @@
try {
std::filesystem::create_hard_link(target, linkFile);
} catch (const std::exception& e) {
- //JAMI_ERR("Couldn't create hard link: %s", e.what());
+ //JAMI_ERR("Unable to create hard link: %s", e.what());
return false;
}
return true;
@@ -155,7 +155,7 @@
std::vector<uint8_t> buffer;
std::ifstream file(path, std::ios::binary);
if (!file)
- throw std::runtime_error("Can't read file: " + path.string());
+ throw std::runtime_error("Unable to read file: " + path.string());
file.seekg(0, std::ios::end);
auto size = file.tellg();
if (size > std::numeric_limits<unsigned>::max())
@@ -163,7 +163,7 @@
buffer.resize(size);
file.seekg(0, std::ios::beg);
if (!file.read((char*) buffer.data(), size))
- throw std::runtime_error("Can't load file: " + path.string());
+ throw std::runtime_error("Unable to load file: " + path.string());
return buffer;
}
@@ -172,7 +172,7 @@
{
std::ofstream file(path, std::ios::trunc | std::ios::binary);
if (!file.is_open()) {
- //JAMI_ERR("Could not write data to %s", path.c_str());
+ //JAMI_ERR("Unable to write data to %s", path.c_str());
return;
}
file.write((char*) data, data_size);
@@ -208,13 +208,13 @@
HANDLE h
= CreateFileA(path.c_str(), GENERIC_WRITE, 0, 0, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0);
if (h == INVALID_HANDLE_VALUE) {
- // JAMI_WARN("Can not open file %s for erasing.", path.c_str());
+ // JAMI_WARN("Unable to open file %s for erasing.", path.c_str());
return false;
}
LARGE_INTEGER size;
if (!GetFileSizeEx(h, &size)) {
- // JAMI_WARN("Can not erase file %s: GetFileSizeEx() failed.", path.c_str());
+ // JAMI_WARN("Unable to erase file %s: GetFileSizeEx() failed.", path.c_str());
CloseHandle(h);
return false;
}
@@ -231,7 +231,7 @@
try {
buffer = new char[ERASE_BLOCK];
} catch (std::bad_alloc& ba) {
- // JAMI_WARN("Can not allocate buffer for erasing %s.", path.c_str());
+ // JAMI_WARN("Unable to allocate buffer for erasing %s.", path.c_str());
CloseHandle(h);
return false;
}
@@ -267,7 +267,7 @@
{
struct stat st;
if (stat(path.c_str(), &st) == -1) {
- //JAMI_WARN("Can not erase file %s: fstat() failed.", path.c_str());
+ //JAMI_WARN("Unable to erase file %s: fstat() failed.", path.c_str());
return false;
}
// Remove read-only flag if possible
@@ -275,7 +275,7 @@
int fd = open(path.c_str(), O_WRONLY);
if (fd == -1) {
- //JAMI_WARN("Can not open file %s for erasing.", path.c_str());
+ //JAMI_WARN("Unable to open file %s for erasing.", path.c_str());
return false;
}
diff --git a/src/ice_transport.cpp b/src/ice_transport.cpp
index a860ec3..16e9fb7 100644
--- a/src/ice_transport.cpp
+++ b/src/ice_transport.cpp
@@ -253,7 +253,7 @@
IpAddr ip {info.uri};
- // Given URI cannot be DNS resolved or not IPv4 or IPv6?
+ // Given URI is unable to be DNS resolved or not IPv4 or IPv6?
// This prevents a crash into PJSIP when ip.toString() is called.
if (ip.getFamily() == AF_UNSPEC) {
/*JAMI_DBG("[ice (%s)] STUN server '%s' not used, unresolvable address",
@@ -902,7 +902,7 @@
if (af != pj_AF_INET() and af != pj_AF_INET6()) {
if (logger_)
- logger_->error("Invalid address familly ({})", af);
+ logger_->error("Invalid address family ({})", af);
return false;
}
@@ -1722,7 +1722,7 @@
if (!remote) {
if (pimpl_->logger_)
- pimpl_->logger_->error("[ice:{}] can't find remote address for component {:d}", fmt::ptr(pimpl_), compId);
+ pimpl_->logger_->error("[ice:{}] Unable to find remote address for component {:d}", fmt::ptr(pimpl_), compId);
errno = EINVAL;
return -1;
}
diff --git a/src/ip_utils.cpp b/src/ip_utils.cpp
index 25e1f40..42d2230 100644
--- a/src/ip_utils.cpp
+++ b/src/ip_utils.cpp
@@ -100,7 +100,7 @@
// Cycle through available interfaces.
for (ifa = ifap; ifa != NULL; ifa = ifa->ifa_next) {
// Skip loopback, point-to-point and down interfaces.
- // except don't skip down interfaces if we're trying to get
+ // except don't skip down interfaces if we're attempting to get
// a list of configurable interfaces.
if ((ifa->ifa_flags & IFF_LOOPBACK) || (!(ifa->ifa_flags & IFF_UP))) {
continue;
@@ -155,7 +155,7 @@
strncpy(ifReq.ifr_name, pifReq->ifr_name, sizeof(ifReq.ifr_name));
ioctl(localSock, SIOCGIFFLAGS, &ifReq);
// Skip loopback, point-to-point and down interfaces.
- // except don't skip down interfaces if we're trying to get
+ // except don't skip down interfaces if we're attempting to get
// a list of configurable interfaces.
if ((ifReq.ifr_flags & IFF_LOOPBACK) || (!(ifReq.ifr_flags & IFF_UP))) {
continue;
@@ -205,7 +205,7 @@
char localHostBuf[INET_ADDRSTRLEN];
auto hostInfo = ip_utils::getHostName();
if (hostInfo.address.empty()) {
- // JAMI_WARN("Couldn't find local host");
+ // JAMI_WARN("Unable to find local host");
return {};
} else {
return IpAddr(ip_utils::getGateway(hostInfo.address, ip_utils::subnet_mask::prefix_24bit));
@@ -270,14 +270,14 @@
if (status == PJ_SUCCESS) {
return ip_addr;
}
- // JAMI_WARN("Could not get preferred address familly (%s)",
+ // JAMI_WARN("Unable to get preferred address family (%s)",
// (family == pj_AF_INET6()) ? "IPv6" : "IPv4");
family = (family == pj_AF_INET()) ? pj_AF_INET6() : pj_AF_INET();
status = pj_gethostip(family, ip_addr.pjPtr());
if (status == PJ_SUCCESS) {
return ip_addr;
}
- // JAMI_ERR("Could not get local IP");
+ // JAMI_ERR("Unable to get local IP");
return ip_addr;
}
@@ -294,14 +294,14 @@
int fd = socket(unix_family, SOCK_DGRAM, 0);
if (fd < 0) {
- // JAMI_ERR("Could not open socket: %m");
+ // JAMI_ERR("Unable to open socket: %m");
return addr;
}
if (unix_family == AF_INET6) {
int val = family != pj_AF_UNSPEC();
if (setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, (void*) &val, sizeof(val)) < 0) {
- // JAMI_ERR("Could not setsockopt: %m");
+ // JAMI_ERR("Unable to setsockopt: %m");
close(fd);
return addr;
}
diff --git a/src/security/certstore.cpp b/src/security/certstore.cpp
index b78d63f..629f4c7 100644
--- a/src/security/certstore.cpp
+++ b/src/security/certstore.cpp
@@ -98,7 +98,7 @@
fileutils::loadFile(crl)));
} catch (const std::exception& e) {
if (logger_)
- logger_->warn("Can't load revocation list: %s", e.what());
+ logger_->warn("Unable to load revocation list: %s", e.what());
}
}
@@ -126,7 +126,7 @@
}
} catch (const std::exception& e) {
if (logger_)
- logger_->warn("Can't load OCSP revocation status: {:s}", e.what());
+ logger_->warn("Unable to load OCSP revocation status: {:s}", e.what());
}
}
}
@@ -183,7 +183,7 @@
}
} catch (const std::exception& e) {
if (logger_)
- logger_->warn("Can't load certificate: {:s}", e.what());
+ logger_->warn("Unable to load certificate: {:s}", e.what());
}
return {};
}
@@ -296,7 +296,7 @@
ids.emplace_back(e.first->first);
} catch (const std::exception& e) {
if (logger_)
- logger_->warn("Can't load certificate: {:s}", e.what());
+ logger_->warn("Unable to load certificate: {:s}", e.what());
}
}
paths_.emplace(path, std::move(scerts));
@@ -432,7 +432,7 @@
pinRevocationList(id, *crl);
} catch (...) {
if (logger_)
- logger_->warn("Can't add revocation list");
+ logger_->warn("Unable to add revocation list");
}
}
@@ -576,7 +576,7 @@
crt_status.second.allowed = allowed;
setStoreCertStatus(*cert, allowed);
} else {
- // Can't find certificate
+ // Unable to find certificate
unknownCertStatus_[cert_id].allowed = allowed;
}
} else {
diff --git a/src/security/diffie-hellman.cpp b/src/security/diffie-hellman.cpp
index 9c69f8b..cfba720 100644
--- a/src/security/diffie-hellman.cpp
+++ b/src/security/diffie-hellman.cpp
@@ -127,7 +127,7 @@
}
return params;
}
- // JAMI_ERR("Can't generate DH params.");
+ // JAMI_ERR("Unable to generate DH params.");
return {};
}
}
diff --git a/src/security/threadloop.h b/src/security/threadloop.h
index 67b43ff..b1cfdef 100644
--- a/src/security/threadloop.h
+++ b/src/security/threadloop.h
@@ -95,7 +95,7 @@
void wait_for(const std::chrono::duration<Rep, Period>& rel_time)
{
if (std::this_thread::get_id() != get_id())
- throw std::runtime_error("can not call wait_for outside thread context");
+ throw std::runtime_error("Unable to call wait_for outside thread context");
std::unique_lock lk(mutex_);
cv_.wait_for(lk, rel_time, [this]() { return isStopping(); });
@@ -105,7 +105,7 @@
bool wait_for(const std::chrono::duration<Rep, Period>& rel_time, Pred&& pred)
{
if (std::this_thread::get_id() != get_id())
- throw std::runtime_error("can not call wait_for outside thread context");
+ throw std::runtime_error("Unable to call wait_for outside thread context");
std::unique_lock lk(mutex_);
return cv_.wait_for(lk, rel_time, [this, pred] { return isStopping() || pred(); });
@@ -115,7 +115,7 @@
void wait(Pred&& pred)
{
if (std::this_thread::get_id() != get_id())
- throw std::runtime_error("Can not call wait outside thread context");
+ throw std::runtime_error("Unable to call wait outside thread context");
std::unique_lock lk(mutex_);
cv_.wait(lk, [this, p = std::forward<Pred>(pred)] { return isStopping() || p(); });
diff --git a/src/security/tls_session.cpp b/src/security/tls_session.cpp
index 8d3539a..4e6952e 100644
--- a/src/security/tls_session.cpp
+++ b/src/security/tls_session.cpp
@@ -496,7 +496,7 @@
params_.ca_list.c_str(),
GNUTLS_X509_FMT_DER);
if (ret < 0)
- throw std::runtime_error("can't load CA " + params_.ca_list + ": "
+ throw std::runtime_error("Unable to load CA " + params_.ca_list + ": "
+ std::string(gnutls_strerror(ret)));
if (params_.logger)
@@ -531,7 +531,7 @@
certs.size(),
params_.cert_key->x509_key);
if (ret < 0)
- throw std::runtime_error("can't load certificate: " + std::string(gnutls_strerror(ret)));
+ throw std::runtime_error("Unable to load certificate: " + std::string(gnutls_strerror(ret)));
if (params_.logger)
params_.logger->d("[TLS] User identity loaded");
diff --git a/src/string_utils.cpp b/src/string_utils.cpp
index 1c94abc..56533d1 100644
--- a/src/string_utils.cpp
+++ b/src/string_utils.cpp
@@ -44,11 +44,11 @@
int srcLength = (int) str.length();
int requiredSize = MultiByteToWideChar(codePage, 0, str.c_str(), srcLength, nullptr, 0);
if (!requiredSize) {
- throw std::runtime_error("Can't convert string to wstring");
+ throw std::runtime_error("Unable to convert string to wstring");
}
std::wstring result((size_t) requiredSize, 0);
if (!MultiByteToWideChar(codePage, 0, str.c_str(), srcLength, &(*result.begin()), requiredSize)) {
- throw std::runtime_error("Can't convert string to wstring");
+ throw std::runtime_error("Unable to convert string to wstring");
}
return result;
}
@@ -59,12 +59,12 @@
int srcLength = (int) wstr.length();
int requiredSize = WideCharToMultiByte(codePage, 0, wstr.c_str(), srcLength, nullptr, 0, 0, 0);
if (!requiredSize) {
- throw std::runtime_error("Can't convert wstring to string");
+ throw std::runtime_error("Unable to convert wstring to string");
}
std::string result((size_t) requiredSize, 0);
if (!WideCharToMultiByte(
codePage, 0, wstr.c_str(), srcLength, &(*result.begin()), requiredSize, 0, 0)) {
- throw std::runtime_error("Can't convert wstring to string");
+ throw std::runtime_error("Unable to convert wstring to string");
}
return result;
}
@@ -76,7 +76,7 @@
char buf[64];
int len = snprintf(buf, sizeof(buf), "%-.*G", 16, value);
if (len <= 0)
- throw std::invalid_argument {"can't parse double"};
+ throw std::invalid_argument {"Unable to parse double"};
return {buf, (size_t) len};
}
@@ -91,7 +91,7 @@
{
uint64_t id;
if (auto [p, ec] = std::from_chars(str.data(), str.data()+str.size(), id, 16); ec != std::errc()) {
- throw std::invalid_argument("Can't parse id: " + str);
+ throw std::invalid_argument("Unable to parse id: " + str);
}
return id;
}
diff --git a/src/upnp/protocol/natpmp/nat_pmp.cpp b/src/upnp/protocol/natpmp/nat_pmp.cpp
index 60d6bf5..c7e3d6f 100644
--- a/src/upnp/protocol/natpmp/nat_pmp.cpp
+++ b/src/upnp/protocol/natpmp/nat_pmp.cpp
@@ -74,7 +74,7 @@
igd_->setPublicIp(IpAddr());
igd_->setUID("");
- if (logger_) logger_->debug("NAT-PMP: Trying to initialize IGD");
+ if (logger_) logger_->debug("NAT-PMP: Attempting to initialize IGD");
int err = initnatpmp(&natpmpHdl_, 0, 0);
@@ -82,10 +82,10 @@
if (logger_) logger_->warn("NAT-PMP: Initializing IGD using default gateway failed!");
const auto& localGw = ip_utils::getLocalGateway();
if (not localGw) {
- if (logger_) logger_->warn("NAT-PMP: Couldn't find valid gateway on local host");
+ if (logger_) logger_->warn("NAT-PMP: Unable to find valid gateway on local host");
err = NATPMP_ERR_CANNOTGETGATEWAY;
} else {
- if (logger_) logger_->warn("NAT-PMP: Trying to initialize using detected gateway {}",
+ if (logger_) logger_->warn("NAT-PMP: Attempting to initialize using detected gateway {}",
localGw.toString());
struct in_addr inaddr;
inet_pton(AF_INET, localGw.toString().c_str(), &inaddr);
@@ -94,7 +94,7 @@
}
if (err < 0) {
- if (logger_) logger_->error("NAT-PMP: Can't initialize libnatpmp -> {}", getNatPmpErrorStr(err));
+ if (logger_) logger_->error("NAT-PMP: Unable to initialize libnatpmp -> {}", getNatPmpErrorStr(err));
return;
}
@@ -206,7 +206,7 @@
}
});
} else {
- if (logger_) logger_->warn("NAT-PMP: Setup failed after {} trials. NAT-PMP will be disabled!",
+ if (logger_) logger_->warn("NAT-PMP: Setup failed after {} attempts. NAT-PMP will be disabled!",
MAX_RESTART_SEARCH_RETRIES);
}
}
@@ -440,7 +440,7 @@
if (!responseValid) {
// Unfortunately, libnatpmp only allows reading one response per request sent; calling
// readResponse again at this point would result in a NATPMP_ERR_NOPENDINGREQ error.
- // Since we can't know whether the mapping was actually created or not, we return an
+ // Since it is unable to known whether the mapping was actually created or not, we return an
// error to ensure the caller won't attempt to use a port mapping that doesn't exist.
return NATPMP_ERR_INVALIDARGS;
}
diff --git a/src/upnp/protocol/pupnp/pupnp.cpp b/src/upnp/protocol/pupnp/pupnp.cpp
index afb110a..b49a43a 100644
--- a/src/upnp/protocol/pupnp/pupnp.cpp
+++ b/src/upnp/protocol/pupnp/pupnp.cpp
@@ -29,7 +29,7 @@
constexpr static const char* ACTION_GET_STATUS_INFO {"GetStatusInfo"};
constexpr static const char* ACTION_GET_EXTERNAL_IP_ADDRESS {"GetExternalIPAddress"};
-// Error codes returned by router when trying to remove ports.
+// Error codes returned by router when attempting to remove ports.
constexpr static int ARRAY_IDX_INVALID = 713;
constexpr static int CONFLICT_IN_MAPPING = 718;
@@ -119,21 +119,21 @@
initialized_ = true;
return;
}else {
- if (logger_) logger_->error("PUPnP: Can't initialize libupnp: {}", UpnpGetErrorMessage(upnp_err));
+ if (logger_) logger_->error("PUPnP: Unable to initialize libupnp: {}", UpnpGetErrorMessage(upnp_err));
UpnpFinish();
initialized_ = false;
return;
}
}
- // Disable embedded WebServer if any.
+ // Disable embedded Web server if any.
if (UpnpIsWebserverEnabled() == 1) {
- if (logger_) logger_->warn("PUPnP: Web-server is enabled. Disabling");
+ if (logger_) logger_->warn("PUPnP: Web server is enabled. Disabling");
UpnpEnableWebserver(0);
if (UpnpIsWebserverEnabled() == 1) {
- if (logger_) logger_->error("PUPnP: Could not disable Web-server!");
+ if (logger_) logger_->error("PUPnP: Unable to disable Web server!");
} else {
- if (logger_) logger_->debug("PUPnP: Web-server successfully disabled");
+ if (logger_) logger_->debug("PUPnP: Web server successfully disabled");
}
}
@@ -173,7 +173,7 @@
// Register Upnp control point.
int upnp_err = UpnpRegisterClient(ctrlPtCallback, this, &ctrlptHandle_);
if (upnp_err != UPNP_E_SUCCESS) {
- if (logger_) logger_->error("PUPnP: Can't register client: {}", UpnpGetErrorMessage(upnp_err));
+ if (logger_) logger_->error("PUPnP: Unable to register client: {}", UpnpGetErrorMessage(upnp_err));
} else {
if (logger_) logger_->debug("PUPnP: Successfully registered client");
clientRegistered_ = true;
@@ -321,7 +321,7 @@
}
if (igdSearchCounter_++ >= PUPNP_MAX_RESTART_SEARCH_RETRIES) {
- if (logger_) logger_->warn("PUPnP: Setup failed after {:d} trials. PUPnP will be disabled!",
+ if (logger_) logger_->warn("PUPnP: Setup failed after {:d} attempts. PUPnP will be disabled!",
PUPNP_MAX_RESTART_SEARCH_RETRIES);
return;
}
@@ -492,7 +492,7 @@
if (const auto& localGw = ip_utils::getLocalGateway()) {
igd_candidate->setLocalIp(localGw);
} else {
- if (logger_) logger_->warn("PUPnP: Could not set internal address for IGD candidate {}",
+ if (logger_) logger_->warn("PUPnP: Unable to set internal address for IGD candidate {}",
igd_candidate->getUID().c_str());
return false;
}
@@ -856,7 +856,7 @@
int upnp_err = UpnpDownloadXmlDoc(locationUrl.c_str(), &doc_container_ptr);
std::lock_guard lk(ongoingOpsMtx_);
- // Trying to use libupnp functions after UpnpFinish has been called (which may
+ // Attempting to use libupnp functions after UpnpFinish has been called (which may
// be the case if destroying_ is true) can cause errors. It's probably not a
// problem here, but return early just in case.
if (destroying_)
@@ -1029,7 +1029,7 @@
auto actionRequest = UpnpActionComplete_get_ActionRequest(a_event);
// Abort if there is no action to process.
if (actionRequest == nullptr) {
- if (logger_) logger_->warn("PUPnP: Can't get the Action Request data from the event");
+ if (logger_) logger_->warn("PUPnP: Unable to get the Action Request data from the event");
break;
}
@@ -1089,7 +1089,7 @@
// Check the UDN to see if its already in our device list.
std::string UDN(getFirstDocItem(doc, "UDN"));
if (UDN.empty()) {
- if (logger_) logger_->warn("PUPnP: could not find UDN in description document of device");
+ if (logger_) logger_->warn("PUPnP: Unable to find UDN in description document of device");
return nullptr;
} else {
std::lock_guard lk(pupnpMutex_);
diff --git a/src/upnp/upnp_context.cpp b/src/upnp/upnp_context.cpp
index b7ec7c9..5a3d8a2 100644
--- a/src/upnp/upnp_context.cpp
+++ b/src/upnp/upnp_context.cpp
@@ -395,7 +395,7 @@
}
if (mapPtr->isAvailable()) {
- if (logger_) logger_->warn("Trying to release an unused mapping {}", mapPtr->toString());
+ if (logger_) logger_->warn("Attempting to release an unused mapping {}", mapPtr->toString());
return;
}
@@ -488,7 +488,7 @@
}
// Very unlikely to get here.
- if (logger_) logger_->error("Could not find an available port after {} trials", MAX_REQUEST_RETRIES);
+ if (logger_) logger_->error("Unable to find an available port after {} attempts", MAX_REQUEST_RETRIES);
return 0;
}
@@ -534,7 +534,7 @@
registerMapping(map);
} else {
// Very unlikely to get here!
- if (logger_) logger_->error("Cannot provision port: no available port number");
+ if (logger_) logger_->error("Unable to provision port: no available port number");
return;
}
}
@@ -609,7 +609,7 @@
currentIgd_->getUID(),
currentIgd_->toString());
} else {
- if (logger_) logger_->warn("Couldn't update current IGD: no valid IGD was found");
+ if (logger_) logger_->warn("Unable to update current IGD: no valid IGD was found");
}
}
@@ -680,7 +680,7 @@
const auto& igd = getCurrentIgd();
if (!igd) {
- if (logger_) logger_->debug("Cannot renew mappings: no valid IGD available");
+ if (logger_) logger_->debug("Unable to renew mappings: no valid IGD available");
return;
}
@@ -1223,7 +1223,7 @@
if (logger_) logger_->debug("Unregistered mapping {}", map->toString());
} else {
// The mapping may already be un-registered. Just ignore it.
- if (logger_) logger_->debug("Can't unregister mapping {} [{}] since it doesn't have a local match",
+ if (logger_) logger_->debug("Unable to unregister mapping {} [{}] since it doesn't have a local match",
map->toString(),
map->getProtocolName());
}