IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jul 17, 2014, 1:09:03 PM (12 years ago)
Author:
eugene
Message:

minor debugging code

File:
1 edited

Legend:

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

    r27435 r37070  
    2525    return (PCLIENT_DOWN);
    2626  }
    27  
     27
    2828  // prepare host to accept response
    2929  host[0].response_state = response_state;
     
    3535  return (PCLIENT_GOOD);
    3636}
    37  
     37
    3838// check for response; message must end with specified string.
    3939// accumulate the response in the buffer
     
    4747  ASSERT (response != NULL, "response missing");
    4848  ASSERT (buffer != NULL, "buffer missing");
     49
     50  // INITTIME;
    4951
    5052  /* avoid blocking very long on read, test every 100 usec, up to 0.1 sec */
     
    6668    return (PCLIENT_DOWN);
    6769  }
    68   if (line == NULL) return (PCLIENT_HUNG);
    69   if (status == -1) return (PCLIENT_HUNG);
     70  if (line == NULL) {
     71      // MARKTIME ("-- client hung (line NULL): %s : %f sec\n", host[0].hostname, dtime);
     72      return (PCLIENT_HUNG);
     73  }
     74  if (status == -1) {
     75      // MARKTIME ("-- client hung (status -1): %s : %f sec\n", host[0].hostname, dtime);
     76      return (PCLIENT_HUNG);
     77  }
    7078
    7179  // fprintf (stderr, "response: %s\n", buffer[0].buffer);
     
    7583
    7684/* memstr returns a view, not an allocated string : don't free */
    77 /* ReadtoIOBuffer returns : 
     85/* ReadtoIOBuffer returns :
    7886    0 - pipe closed
    7987   -1 - no more data in pipe, data not ready
Note: See TracChangeset for help on using the changeset viewer.