Changeset 18366 for trunk/ippTools/src/pxchip.c
- Timestamp:
- Jun 29, 2008, 3:02:07 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/pxchip.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/pxchip.c
r17161 r18366 35 35 36 36 // check that state is a valid string value 37 if (!( 38 (strncmp(state, "run", 4) == 0) 39 || (strncmp(state, "stop", 5) == 0) 40 || (strncmp(state, "reg", 4) == 0) 41 ) 42 ) { 43 psError(PS_ERR_UNKNOWN, false, 44 "invalid chipRun state: %s", state); 37 if (!pxIsValidState(state)) { 38 psError(PS_ERR_UNKNOWN, false, "invalid chipRun state: %s", state); 45 39 return false; 46 40 } … … 63 57 64 58 // check that state is a valid string value 65 if (!( 66 (strncmp(state, "run", 4) == 0) 67 || (strncmp(state, "stop", 5) == 0) 68 || (strncmp(state, "reg", 4) == 0) 69 ) 70 ) { 71 psError(PS_ERR_UNKNOWN, false, 72 "invalid chipRun state: %s", state); 59 if (!pxIsValidState(state)) { 60 psError(PS_ERR_UNKNOWN, false, "invalid chipRun state: %s", state); 73 61 return false; 74 62 } 63 75 64 76 65 psString query = psStringCopy("UPDATE chipRun JOIN rawExp USING(exp_id) SET state = '%s'"); … … 151 140 0x0, // chip_id 152 141 exp_id, 153 " run", // state142 "new", // state 154 143 workdir, 155 144 "dirty", // workdir_state … … 167 156 return psDBLastInsertID(config->dbh); 168 157 } 158
Note:
See TracChangeset
for help on using the changeset viewer.
