Skip to content
Snippets Groups Projects
Commit 9ee0fb9e authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Copy event last-run info from global config into node config

Fixes issue introduced in last commit to this file (the each-node-has-its-own-config-in-memory enhancement) that would prevent users from logging in because their time was reduced for an upcoming event that had already run. The change assumes the event thread is running (its the thing that reads the event last-run info from time.dab). Thanks to mlong for the report.
parent f348a267
No related branches found
No related tags found
No related merge requests found
......@@ -5710,8 +5710,6 @@ NO_SSH:
scfg_t* cfg = &node_scfg[i - 1];
if(cfg->size != sizeof(*cfg) || (node.misc & NODE_RRUN)) {
sbbs->bprintf("Loading configuration...");
free_cfg(cfg);
free_text(node_text[i - 1]);
cfg->size = sizeof(*cfg);
cfg->node_num = i;
SAFECOPY(cfg->ctrl_dir, startup->ctrl_dir);
......@@ -5736,6 +5734,9 @@ NO_SSH:
}
sbbs->bputs(crlf);
}
// Copy event last-run info from global config
for(int e=0; e < cfg->total_events && e < scfg.total_events; e++)
cfg->event[e]->last = scfg.event[e]->last;
node_socket[i-1]=client_socket;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment