lib/upnp: fix bad std::chrono cast

libupnp provides seconds, not whatever time unit is used by
std::chrono::steady_clock.
This commit is contained in:
Max Kellermann 2017-01-23 19:16:14 +01:00
parent 1776015c6c
commit 32a64481f2
2 changed files with 3 additions and 1 deletions

2
NEWS
View File

@ -4,6 +4,8 @@ ver 0.20.3 (not yet released)
* database * database
- proxy: fix error "terminate called after throwing ..." - proxy: fix error "terminate called after throwing ..."
- proxy: make connect errors during startup non-fatal - proxy: make connect errors during startup non-fatal
* neighbor
- upnp: fix premature expiry
* replay gain: don't reset ReplayGain levels when unpausing playback * replay gain: don't reset ReplayGain levels when unpausing playback
* silence surround channels when converting from stereo * silence surround channels when converting from stereo
* use shortcuts such as "dsd64" in log messages * use shortcuts such as "dsd64" in log messages

View File

@ -62,7 +62,7 @@ class UPnPDeviceDirectory final : UpnpCallback {
DiscoveredTask(const Upnp_Discovery *disco) DiscoveredTask(const Upnp_Discovery *disco)
:url(disco->Location), :url(disco->Location),
device_id(disco->DeviceId), device_id(disco->DeviceId),
expires(disco->Expires) {} expires(std::chrono::seconds(disco->Expires)) {}
}; };
/** /**