IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 3, 2021, 2:12:35 PM (5 years ago)
Author:
eugene
Message:

stop threads before freeing data when QUIT is called; fuzz added to last task execution was not correctly added to usec -- this made fast tasks run many invalid attempts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi/pantasks/controller_threads.c

    r39457 r41483  
    55static int CheckControllerRun = FALSE;
    66
     7static int ControllerThreadRuns = TRUE;
     8
    79void CheckControllerSetState (int state) {
    810  CheckControllerRun = state;
     
    1012int CheckControllerGetState () {
    1113  return (CheckControllerRun);
     14}
     15
     16void QuitControllerThread (void) {
     17  ControllerThreadRuns = FALSE;
    1218}
    1319
     
    2632  }
    2733
    28   while (1) {
     34  while (ControllerThreadRuns) {
    2935
    3036    // check for thread suspend
     
    4753    usleep (500000); // allow other threads a chance to run
    4854  }
     55  return NULL;
    4956}
Note: See TracChangeset for help on using the changeset viewer.