mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2026-01-05 08:50:04 +00:00
Only send live checks when the connection has been silent for a while.
Also: * Made the timeout configurable * Removed the stale randomcharacters config option * Switched to time_t for time values, even though it doesn't really matter that much * Halved the keepAliveTimer frequency
This commit is contained in:
@@ -172,15 +172,15 @@ public:
|
||||
};
|
||||
|
||||
class CNServer;
|
||||
typedef void (*TimerHandler)(CNServer* serv, uint64_t time);
|
||||
typedef void (*TimerHandler)(CNServer* serv, time_t time);
|
||||
|
||||
// timer struct
|
||||
struct TimerEvent {
|
||||
TimerHandler handlr;
|
||||
uint64_t delta; // time to be added to the current time on reset
|
||||
uint64_t scheduledEvent; // time to call handlr()
|
||||
time_t delta; // time to be added to the current time on reset
|
||||
time_t scheduledEvent; // time to call handlr()
|
||||
|
||||
TimerEvent(TimerHandler h, uint64_t d): handlr(h), delta(d) {
|
||||
TimerEvent(TimerHandler h, time_t d): handlr(h), delta(d) {
|
||||
scheduledEvent = 0;
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user