Changeset 23381 for trunk/ippTools/src/chiptool.c
- Timestamp:
- Mar 18, 2009, 10:10:16 AM (17 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/chiptool.c (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/chiptool.c
r23339 r23381 209 209 return false; 210 210 } 211 211 // 212 212 // queue the exp 213 213 if (!pxchipQueueByExpTag(config, exp_id, workdir, label, reduction, expgroup, dvodb, tess_id, end_stage)) { … … 415 415 PXOPT_LOOKUP_F32(n_cr, config->args, "-n_cr", false, false); 416 416 PXOPT_LOOKUP_STR(path_base, config->args, "-path_base", false, false); 417 PXOPT_LOOKUP_BOOL(magicked, config->args, "-magicked", false); 417 418 418 419 // default values … … 490 491 path_base, 491 492 code, 492 0 // magic_ds_id493 magicked 493 494 )) { 494 495 // rollback … … 540 541 PXOPT_COPY_STR(config->args, where, "-reduction", "chipRun.reduction", "=="); 541 542 PXOPT_COPY_STR(config->args, where, "-label", "chipRun.label", "LIKE"); 543 PXOPT_COPY_S32(config->args, where, "-magicked", "chipRun.magicked", "=="); 542 544 543 545 psString query = pxDataGet("chiptool_processedimfile.sql"); … … 1137 1139 } 1138 1140 1139 // set chipRun.state to 'stop' 1140 if (!pxchipRunSetState(config, chipRun->chip_id, "full" )) {1141 // set chipRun.state to 'stop' and update the magicked state 1142 if (!pxchipRunSetState(config, chipRun->chip_id, "full", chipRun->magicked)) { 1141 1143 psError(PS_ERR_UNKNOWN, false, "failed to change chipRun.state for chip_id: %" PRId64, chipRun->chip_id); 1142 1144 psFree(chipRun); … … 1209 1211 } 1210 1212 1211 // note only updates if chipRun.state = run_state 1212 if (!p_psDBRunQueryF(config->dbh, query, data_state, chip_id, class_id, run_state)) { 1213 psString set_magic = ""; 1214 if (!strcmp(data_state, "full")) { 1215 // copy the magicked state from the input to the output when transitioning to full state 1216 set_magic = "\n , chipProcessedImfile.magicked = rawImfile.magicked"; 1217 } 1218 1219 if (!p_psDBRunQueryF(config->dbh, query, data_state, set_magic, chip_id, class_id)) { 1220 psFree(query); 1213 1221 psError(PS_ERR_UNKNOWN, false, "database error"); 1214 1222 // rollback … … 1227 1235 query = pxDataGet("chiptool_change_exp_state.sql"); 1228 1236 if (!p_psDBRunQueryF(config->dbh, query, data_state, chip_id, data_state)) { 1237 psFree(query); 1229 1238 // rollback 1230 1239 if (!psDBRollback(config->dbh)) { … … 1234 1243 return false; 1235 1244 } 1245 psFree(query); 1236 1246 1237 1247 if (!psDBCommit(config->dbh)) {
Note:
See TracChangeset
for help on using the changeset viewer.
