Bump version to 0.6.4 for testing, integrate software updater auto-check into PacketDecoder decode path and main loop.
This commit is contained in:
@@ -76,6 +76,9 @@ public:
|
||||
|
||||
/**
|
||||
* Check for updates now regardless of last check time or version
|
||||
*
|
||||
* This only starts a check if one is not in progress. Otherwise it does
|
||||
* nothing.
|
||||
*/
|
||||
inline void checkNow()
|
||||
{
|
||||
@@ -87,6 +90,17 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Check for updates now if it's been longer than ZT_UPDATE_MAX_INTERVAL
|
||||
*
|
||||
* This is called periodically from the main loop.
|
||||
*/
|
||||
inline void checkIfMaxIntervalExceeded(uint64_t now)
|
||||
{
|
||||
if ((now - _lastUpdateAttempt) >= ZT_UPDATE_MAX_INTERVAL)
|
||||
checkNow();
|
||||
}
|
||||
|
||||
/**
|
||||
* Pack three-component version into a 64-bit integer
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user