Commit c1ba8f64 authored by Ivan Vilata-i-Balaguer's avatar Ivan Vilata-i-Balaguer
Browse files

Report friendly name of troublesome IGDs.

parent b441f98d
......@@ -103,14 +103,16 @@ private:
auto query_begin = steady_clock::now();
auto curr_duration = get_mapping_duration(igd, mapping_desc, cancel, yield);
if (curr_duration && *curr_duration > lease_duration) {
LOG_WARN("UPnP: IGD reports excessive mapping lease duration, ignoring");
LOG_WARN("UPnP: IGD \"", igd.friendly_name(), "\""
" reports excessive mapping lease duration, ignoring");
continue;
}
if (!curr_duration || lease_duration >= *curr_duration + recent_margin) {
// Versions of MiniUPnPd before 2015-07-09 fail to refresh existing mappings,
// see <https://github.com/miniupnp/miniupnp/issues/131>,
// so check actual result and do not count if failed.
LOG_VERBOSE("UPnP: IGD did not add/refresh mapping for \"", mapping_desc, "\""
LOG_VERBOSE("UPnP: IGD \"", igd.friendly_name(), "\""
" did not add/refresh mapping for \"", mapping_desc, "\""
" but reported no error; buggy IGD/router?");
auto mapping_timeout = query_begin + (curr_duration ? *curr_duration : seconds(0));
if (!earlier_buggy_timeout || mapping_timeout < *earlier_buggy_timeout)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment