IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 12, 2008, 12:52:06 PM (18 years ago)
Author:
eugene
Message:

use virtual stacks for host and job queries by user thread

File:
1 edited

Legend:

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

    r7917 r18098  
    4040}
    4141
     42IDtype GetID (char *IDword) {
     43
     44  int Nargs;
     45  IDtype ID;
     46  unsigned short int word0, word1, word2, word3;
     47
     48  Nargs = sscanf (IDword, "%x.%x.%x.%x", &word0, &word1, &word2, &word3);
     49  if (Nargs == 4) {
     50    ID = 0;
     51    ID |= (word0 << 0);
     52    ID |= (word1 << 16);
     53    ID |= (word2 << 32);
     54    ID |= (word3 << 48);
     55    return ID;
     56  }
     57   
     58  ID = strtoll (IDword, &endptr, 10);
     59  if (*endptr == 0) {
     60    return ID;
     61  }
     62
     63  return 0;
     64}
Note: See TracChangeset for help on using the changeset viewer.