simplified
This commit is contained in:
@@ -1471,13 +1471,12 @@ result_t BusHandler::scanAndWait(symbol_t dstAddress, bool loadScanConfig, bool
|
|||||||
}
|
}
|
||||||
if (loadScanConfig) {
|
if (loadScanConfig) {
|
||||||
string file;
|
string file;
|
||||||
if (result == RESULT_ERR_TIMEOUT) {
|
bool timedOut = result == RESULT_ERR_TIMEOUT;
|
||||||
|
if (timedOut || result == RESULT_OK) {
|
||||||
result = loadScanConfigFile(m_messages, dstAddress, file); // try to load even if one message timed out
|
result = loadScanConfigFile(m_messages, dstAddress, file); // try to load even if one message timed out
|
||||||
if (result == RESULT_EMPTY) {
|
if (timedOut && result == RESULT_EMPTY) {
|
||||||
result = RESULT_ERR_TIMEOUT; // back to previous result
|
result = RESULT_ERR_TIMEOUT; // back to previous result
|
||||||
}
|
}
|
||||||
} else if (result == RESULT_OK) {
|
|
||||||
result = loadScanConfigFile(m_messages, dstAddress, file);
|
|
||||||
}
|
}
|
||||||
if (result == RESULT_OK) {
|
if (result == RESULT_OK) {
|
||||||
executeInstructions(m_messages);
|
executeInstructions(m_messages);
|
||||||
|
|||||||
Reference in New Issue
Block a user