Changeset 25835 for trunk/ippTools/src/faketool.c
- Timestamp:
- Oct 14, 2009, 11:06:18 AM (17 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/faketool.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/faketool.c
r25324 r25835 177 177 PXOPT_LOOKUP_STR(tess_id, config->args, "-set_tess_id", false, false); 178 178 PXOPT_LOOKUP_STR(end_stage, config->args, "-set_end_stage", false, false); 179 PXOPT_LOOKUP_STR(data_group, config->args, "-set_data_group", false, false); 180 PXOPT_LOOKUP_STR(dist_group, config->args, "-set_dist_group", false, false); 181 PXOPT_LOOKUP_STR(note, config->args, "-set_note", false, false); 179 182 180 183 // default … … 265 268 266 269 // queue the exp 267 if (!pxfakeQueueByCamID(config, cam_id, workdir, label, reduction, expgroup, dvodb, tess_id, end_stage)) {270 if (!pxfakeQueueByCamID(config, cam_id, workdir, label, data_group ? data_group : label, dist_group, reduction, expgroup, dvodb, tess_id, end_stage, note)) { 268 271 if (!psDBRollback(config->dbh)) { 269 272 psError(PS_ERR_UNKNOWN, false, "database error"); … … 330 333 PXOPT_COPY_F32(config->args, where, "-sun_angle_max", "sun_angle", "<"); 331 334 PXOPT_COPY_STR(config->args, where, "-label", "fakeRun.label", "=="); 332 333 if (!psListLength(where->list) 334 && !psMetadataLookupBool(NULL, config->args, "-all")) { 335 PXOPT_COPY_STR(config->args, where, "-data_group", "fakeRun.data_group", "=="); 336 PXOPT_COPY_STR(config->args, where, "-dist_group", "fakeRun.dist_group", "=="); 337 338 if (!psListLength(where->list)) { 335 339 psFree(where); 336 340 where = NULL; … … 339 343 } 340 344 341 PXOPT_LOOKUP_STR(state, config->args, "-set_state", false, false); 342 PXOPT_LOOKUP_STR(label, config->args, "-set_label", false, false); 343 344 if ((!state) && (!label)) { 345 psError(PXTOOLS_ERR_DATA, false, "parameters are required"); 346 psFree(where); 347 return false; 348 } 349 350 if (state) { 351 // set fakeRun.state to state 352 if (!pxfakeRunSetStateByQuery(config, where, state)) { 353 psFree(where); 354 return false; 355 } 356 } 357 358 if (label) { 359 // set fakeRun.label to label 360 if (!pxfakeRunSetLabelByQuery(config, where, label)) { 361 psFree(where); 362 return false; 363 } 364 } 365 345 psString query = psStringCopy("UPDATE fakeRun JOIN camRun USING(cam_id) JOIN chipRun USING(chip_id) JOIN rawExp USING(exp_id)"); 346 347 // pxUpdateRun gets parameters from config->args and updates 348 bool result = pxUpdateRun(config, where, &query, true); 349 if (!result) { 350 psError(PXTOOLS_ERR_DATA, false, "pxUpdateRun failed"); 351 } 352 353 psFree(query); 366 354 psFree(where); 367 355 368 return true;356 return result; 369 357 } 370 358 … … 1162 1150 fakeRun->workdir, 1163 1151 fakeRun->label, 1152 fakeRun->data_group, 1153 fakeRun->dist_group, 1164 1154 fakeRun->dvodb, 1165 1155 fakeRun->tess_id, 1166 1156 fakeRun->reduction, 1167 fakeRun->end_stage 1157 fakeRun->end_stage, 1158 NULL // note does not propagate 1168 1159 )) { 1169 1160 psError(PS_ERR_UNKNOWN, false, "failed to queue warpRun");
Note:
See TracChangeset
for help on using the changeset viewer.
