Only re-write trigger pages if trigger configuration has changed
This commit is contained in:
parent
4370896f79
commit
ca755039e1
1 changed files with 67 additions and 63 deletions
|
@ -333,8 +333,11 @@ namespace Controller{
|
||||||
|
|
||||||
/*LTS-START*/
|
/*LTS-START*/
|
||||||
static std::map<std::string, IPC::sharedPage> pageForType; // should contain one page for every trigger type
|
static std::map<std::string, IPC::sharedPage> pageForType; // should contain one page for every trigger type
|
||||||
|
static JSON::Value writtenTrigs;
|
||||||
char tmpBuf[NAME_BUFFER_SIZE];
|
char tmpBuf[NAME_BUFFER_SIZE];
|
||||||
|
|
||||||
|
if (writtenTrigs != Storage["config"]["triggers"]){
|
||||||
|
writtenTrigs = Storage["config"]["triggers"];
|
||||||
// for all shm pages that hold triggers
|
// for all shm pages that hold triggers
|
||||||
pageForType.clear();
|
pageForType.clear();
|
||||||
|
|
||||||
|
@ -412,6 +415,7 @@ namespace Controller{
|
||||||
tPage.setEndPos(std::min(i, max));
|
tPage.setEndPos(std::min(i, max));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static bool serverStartTriggered;
|
static bool serverStartTriggered;
|
||||||
if (!serverStartTriggered){
|
if (!serverStartTriggered){
|
||||||
|
|
Loading…
Add table
Reference in a new issue