IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Apr 23, 2008, 3:38:50 PM (18 years ago)
Author:
eugene
Message:

handle comm errors where pclient sends an orphaned prompt

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi/pcontrol/StartJob.c

    r17476 r17477  
    7272  /* check on result of pclient command */
    7373  p = memstr (buffer[0].buffer, "STATUS", buffer[0].Nbuffer);
    74   ASSERT (p != NULL, "missing STATUS in pclient message");
     74  if (p == NULL) {
     75      // failed to get a valid response.  kill the job and try again,
     76      // or accept a running process without a PID?
     77      if (VerboseMode()) gprint (GP_ERR, "failed to get a valid PID, trying to continue without\n");
     78      PutHost (host, PCONTROL_HOST_BUSY, STACK_BOTTOM);
     79      PutJob (job, PCONTROL_JOB_BUSY, STACK_BOTTOM);
     80      gettimeofday (&job[0].start, NULL);
     81      return (TRUE);
     82  }
    7583
    7684  sscanf (p, "%*s %d", &status);
Note: See TracChangeset for help on using the changeset viewer.