ioc: shutdown PVA server via epicsAtExit()
Otherwise is shutdown in global dtor. Better to use epicsAtExit() which has some ordering
This commit is contained in:
@@ -103,10 +103,16 @@ void pvasr(int lvl)
|
||||
}
|
||||
}
|
||||
|
||||
void pva_server_cleanup(void *)
|
||||
{
|
||||
stopPVAServer();
|
||||
}
|
||||
|
||||
void initStartPVAServer(initHookState state)
|
||||
{
|
||||
pvd::Lock G(the_server_lock);
|
||||
if(state==initHookAfterIocRunning && !the_server) {
|
||||
epicsAtExit(&pva_server_cleanup, 0);
|
||||
startitup();
|
||||
|
||||
} else if(state==initHookAtIocPause) {
|
||||
@@ -114,7 +120,6 @@ void initStartPVAServer(initHookState state)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void registerStartPVAServer(void)
|
||||
{
|
||||
epics::iocshRegister<const char*, &startPVAServer>("startPVAServer", "provider names");
|
||||
|
||||
Reference in New Issue
Block a user