if (strstr(reply, "Error while creating snapshot") ||
strstr(reply, "Could not open VM state file") ||
strstr(reply, "State blocked by non-migratable device") ||
+ strstr(reply, "Error: ") ||
(strstr(reply, "Error") && strstr(reply, "while writing VM"))) {
virReportError(VIR_ERR_OPERATION_FAILED,
_("Failed to take snapshot: %s"), reply);
_("Failed to load snapshot: %s"), reply);
goto cleanup;
} else if (strstr(reply, "Could not open VM state file") ||
+ strstr(reply, "Error: ") ||
(strstr(reply, "Error") &&
(strstr(reply, "while loading VM state") ||
strstr(reply, "while activating snapshot on")))) {
} else if (strstr(reply, "Snapshots not supported on device")) {
virReportError(VIR_ERR_OPERATION_INVALID, "%s", reply);
goto cleanup;
- } else if (strstr(reply, "Error") &&
- strstr(reply, "while deleting snapshot")) {
+ } else if (strstr(reply, "Error: ") ||
+ (strstr(reply, "Error") &&
+ strstr(reply, "while deleting snapshot"))) {
virReportError(VIR_ERR_OPERATION_FAILED,
_("Failed to delete snapshot: %s"), reply);
goto cleanup;