ca: fallback to repeater thread if unable to exec caRepeater

Silently fallback to in-process repeater thread on all targets.
Including on host targets when caRepeater executable is unavailable.
This commit is contained in:
Michael Davidsaver
2021-04-19 11:08:49 -07:00
parent a9457fc02b
commit 08b741ed05
2 changed files with 18 additions and 5 deletions

View File

@@ -629,8 +629,8 @@ void epicsStdCall caStartRepeaterIfNotInstalled ( unsigned repeaterPort )
* repeater's port)
*/
osiSpawnDetachedProcessReturn osptr =
osiSpawnDetachedProcess ( "CA Repeater", "caRepeater" );
if ( osptr == osiSpawnDetachedProcessNoSupport ) {
osiSpawnDetachedProcess ( "!CA Repeater", "caRepeater" );
if ( osptr != osiSpawnDetachedProcessSuccess ) {
epicsThreadId tid;
tid = epicsThreadCreate ( "CAC-repeater", epicsThreadPriorityLow,
@@ -639,9 +639,6 @@ void epicsStdCall caStartRepeaterIfNotInstalled ( unsigned repeaterPort )
fprintf ( stderr, "caStartRepeaterIfNotInstalled : unable to create CA repeater daemon thread\n" );
}
}
else if ( osptr == osiSpawnDetachedProcessFail ) {
fprintf ( stderr, "caStartRepeaterIfNotInstalled (): unable to start CA repeater daemon detached process\n" );
}
}
}