Skip to content

Commit

Permalink
Set PVAS_SERVER_PORT
Browse files Browse the repository at this point in the history
  • Loading branch information
mdavidsaver authored and anjohnson committed Nov 1, 2023
1 parent 55ab0fd commit cf483d6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/ioc/PVAServerRegister.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ void startitup() {
// from environment
.push_env()
.build()));

unsigned short port = the_server->getServerPort();
char pbuf[7];
epicsSnprintf(pbuf, sizeof(pbuf)-1, "%u", port);
pbuf[sizeof(pbuf)-1] = '\0';
epicsEnvSet("PVAS_SERVER_PORT", pbuf);
}

void startPVAServer(const char *names)
Expand Down

0 comments on commit cf483d6

Please sign in to comment.