moved last_beacon_time declaration out of thread loop

lastudp
Tom Early 7 years ago
parent 153a862a0a
commit b949b82146

@ -2207,6 +2207,7 @@ void CQnetGateway::APRSBeaconThread()
time_t last_keepalive_time;
time(&last_keepalive_time);
time_t last_beacon_time = 0;
/* This thread is also saying to the APRS_HOST that we are ALIVE */
while (keep_running) {
if (aprs->GetSock() == -1) {
@ -2218,7 +2219,6 @@ void CQnetGateway::APRSBeaconThread()
}
time(&tnow);
time_t last_beacon_time = 0;
if ((tnow - last_beacon_time) > (rptr.aprs_interval * 60)) {
for (short int i=0; i<3; i++) {
if (rptr.mod[i].desc[0] != '\0') {

Loading…
Cancel
Save

Powered by TurnKey Linux.