Replaced INSTALL_ERROR by proper error codes.

This commit is contained in:
Gerhard Hoffmann 2024-04-26 12:47:13 +02:00
parent 3165d77f49
commit 5e7c848fca

View File

@ -841,9 +841,9 @@ private:
QString const &ismasUpdateNews = QString const &ismasUpdateNews =
QString("#M=APISM#C=CMD_EVENT#J=") + QString("#M=APISM#C=CMD_EVENT#J=") +
ismasClient.updateNewsToIsmas( ismasClient.updateNewsToIsmas(
"U0003", _ISMAS_CONTINUE, // U0010 -> even on error: U0002/3 are sent only once
_CLONE_REPOSITORY_FAILURE, _CLONE_REPOSITORY_FAILURE,
IsmasClient::RESULT_CODE::INSTALL_ERROR, IsmasClient::RESULT_CODE::GIT_CLONE_ERROR,
smap[UPDATE_STEP::CHECKOUT_REPOSITORY], smap[UPDATE_STEP::CHECKOUT_REPOSITORY],
QString("CLONING REPOSITORY %1 OR CHECKING OUT BRANCH %2 FAILED") QString("CLONING REPOSITORY %1 OR CHECKING OUT BRANCH %2 FAILED")
.arg(instance->m_customerRepository) .arg(instance->m_customerRepository)
@ -921,9 +921,9 @@ private:
QString const &ismasUpdateNews = QString const &ismasUpdateNews =
QString("#M=APISM#C=CMD_EVENT#J=") + QString("#M=APISM#C=CMD_EVENT#J=") +
ismasClient.updateNewsToIsmas( ismasClient.updateNewsToIsmas(
"U0003", _ISMAS_CONTINUE, // U0010 -> even on error: U0002/3 are sent only once
_PULL_NEW_BRANCH_FAILURE, _PULL_NEW_BRANCH_FAILURE,
IsmasClient::RESULT_CODE::INSTALL_ERROR, IsmasClient::RESULT_CODE::GIT_PULL_ERROR,
smap[UPDATE_STEP::CHECKOUT_BRANCH], smap[UPDATE_STEP::CHECKOUT_BRANCH],
instance->m_ismasMsg.join(' ').toStdString().c_str(), instance->m_ismasMsg.join(' ').toStdString().c_str(),
instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A"); instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A");
@ -979,9 +979,9 @@ private:
QString const &ismasUpdateNews = QString const &ismasUpdateNews =
QString("#M=APISM#C=CMD_EVENT#J=") + QString("#M=APISM#C=CMD_EVENT#J=") +
ismasClient.updateNewsToIsmas( ismasClient.updateNewsToIsmas(
"U0003", _ISMAS_FAILURE, // U0003
_CHECKOUT_BRANCH_FAILURE, _CHECKOUT_BRANCH_FAILURE,
IsmasClient::RESULT_CODE::INSTALL_ERROR, IsmasClient::RESULT_CODE::GIT_SWITCH_BRANCH_ERROR,
smap[UPDATE_STEP::CHECKOUT_BRANCH], smap[UPDATE_STEP::CHECKOUT_BRANCH],
instance->m_ismasMsg.join(' ').toStdString().c_str(), instance->m_ismasMsg.join(' ').toStdString().c_str(),
instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A"); instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A");
@ -1143,7 +1143,7 @@ private:
ismasClient.updateNewsToIsmas( ismasClient.updateNewsToIsmas(
_ISMAS_FAILURE, _ISMAS_FAILURE,
ismasClient.getProgressInPercent(), ismasClient.getProgressInPercent(),
IsmasClient::RESULT_CODE::INSTALL_ERROR, IsmasClient::RESULT_CODE::OPKG_COMMANDS_ERROR,
smap[step], smap[step],
instance->m_ismasMsg.join(' ').toStdString().c_str(), instance->m_ismasMsg.join(' ').toStdString().c_str(),
instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A"); instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A");
@ -1291,7 +1291,7 @@ private:
ismasClient.updateNewsToIsmas( ismasClient.updateNewsToIsmas(
_ISMAS_FAILURE, _ISMAS_FAILURE,
ismasClient.getProgressInPercent(), ismasClient.getProgressInPercent(),
IsmasClient::RESULT_CODE::INSTALL_ERROR, IsmasClient::RESULT_CODE::UPDATE_IN_ERROR_STATE,
smap[UPDATE_STEP::UPDATE_FINALIZE], smap[UPDATE_STEP::UPDATE_FINALIZE],
instance->m_ismasMsg.join(' ').toStdString().c_str(), instance->m_ismasMsg.join(' ').toStdString().c_str(),
instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A"); instance->m_versionInfo.size() >= 1 ? instance->m_versionInfo.at(0).toUtf8().constData() : "N/A");