FACT++  1.0
void triggerRestart ( int  exitVal)

Definition at line 2467 of file feeserver.c.

References cleanUp(), createLogMessage(), and sprintf().

Referenced by initialize(), and restartFeeServer().

2467  {
2468  int status = 0;
2469  char msg[80];
2470 
2471 # ifdef __DEBUG
2472  printf("Triggering restart with exit value: %d\n", exitVal);
2473  fflush(stdout);
2474 # endif
2475  msg[sprintf(msg, "Restarting FeeServer - exit value: %d ", exitVal)] = 0;
2476  createLogMessage(MSG_INFO, msg, 0);
2477 
2478  // should we call cleanUp() before restart
2479  // better not: another possibility to hang ???
2480  // -> cleanUp is in restart implicit ! except opened drivers
2481  // could only be necessary, if some driver cons has to be closed.
2482  cleanUp();
2483  status = pthread_mutex_unlock(&command_mut);
2484 # ifdef __DEBUG
2485  if (status != 0) {
2486  printf("Unlock FeeCommand mutex error: %d\n", status);
2487  fflush(stdout);
2488  }
2489 # endif
2490  // Exit status tells the startScript which type of restart is performed
2491  exit(exitVal);
2492 }
void cleanUp()
Definition: feeserver.c:3159
void createLogMessage(unsigned int type, char *description, char *origin)
Definition: feeserver.c:1530
static pthread_mutex_t command_mut
Definition: feeserver.c:266
sprintf(name1,"NewService%d", i)

+ Here is the call graph for this function:

+ Here is the caller graph for this function: