This commit is contained in:
vanjeff 2012-10-11 09:10:37 +00:00
parent 4ccfd30544
commit ab04e71d33
1 changed files with 5 additions and 9 deletions

View File

@ -598,19 +598,15 @@ SendCommandAndWaitForAckOK (
SendPacketWithoutData (Command);
while (TRUE) {
Status = ReceiveAckPacket (&Ack, Timeout, BreakReceived, CheckSumStatus);
if (Status == RETURN_SUCCESS && Ack == DEBUG_COMMAND_RESEND) {
//
// Resend the last command
//
break;
}
if ((Status == RETURN_SUCCESS && Ack == DEBUG_COMMAND_OK) ||
Status == RETURN_TIMEOUT) {
if (Status == RETURN_SUCCESS && Ack == DEBUG_COMMAND_OK) {
//
// Received Ack OK or timeout
//
return Status;
}
}
if (Status == RETURN_TIMEOUT) {
break;
}
}
}
}