- Timestamp:
- Nov 17, 2011, 2:02:08 PM (15 years ago)
- Location:
- branches/eam_branches/ipp-20111110
- Files:
-
- 3 edited
-
. (modified) (1 prop)
-
ippTools/src (modified) (1 prop)
-
ippTools/src/magicdstool.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20111110
- Property svn:mergeinfo changed
/trunk (added) merged: 32650,32652-32656,32658,32665-32666,32668-32669,32671,32674,32676,32678,32680-32682,32687
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20111110/ippTools/src
- Property svn:mergeinfo changed
/trunk/ippTools/src (added) merged: 32653,32668,32680
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20111110/ippTools/src/magicdstool.c
r32479 r32694 53 53 54 54 static bool setmagicDSRunState(pxConfig *config, psS64 magic_id, psString extraSetString, psMetadata *where, const char *state); 55 static bool validDSRunState(const char *state); 55 56 56 57 # define MODECASE(caseName, func) \ … … 1212 1213 1213 1214 psMetadata *where = psMetadataAlloc(); 1214 // new state (required1215 PXOPT_LOOKUP_STR(new_state, config->args, "-set_state", true, false);1215 // new state 1216 PXOPT_LOOKUP_STR(new_state, config->args, "-set_state", false, false); 1216 1217 // old state (required) 1217 1218 PXOPT_LOOKUP_STR(state, config->args, "-state", true, false); … … 1237 1238 if (!strcmp(state, "failed_revert")) { 1238 1239 new_state = "new"; 1240 } else if (!strcmp(state, "failed_revert_ud")) { 1241 new_state = "update"; 1239 1242 } else if (!strcmp(state, "failed_cleanup")) { 1240 1243 new_state = "goto_cleaned"; … … 1243 1246 return false; 1244 1247 } 1248 } else { 1249 if (!validDSRunState(new_state)) { 1250 psError(PS_ERR_UNKNOWN, true, "unexpected value for new state: %s", new_state); 1251 return false; 1252 } 1245 1253 } 1246 1254 if (!p_psDBRunQueryF(config->dbh, query, new_state)) { 1247 psError(PS_ERR_UNKNOWN, false, "failed to revert");1255 psError(PS_ERR_UNKNOWN, false, "failed to clear state faults"); 1248 1256 psFree(query); 1249 1257 return false; … … 1403 1411 (strcmp(state, "wait") == 0) || 1404 1412 (strcmp(state, "failed_revert") == 0) || 1413 (strcmp(state, "failed_revert_ud") == 0) || 1405 1414 (strcmp(state, "error_cleaned") == 0) || 1406 1415 (strcmp(state, "restored") == 0) ||
Note:
See TracChangeset
for help on using the changeset viewer.
