From 95a2949eda32cbdce0c51f765242cff917338099 Mon Sep 17 00:00:00 2001 From: jiangdi Date: Thu, 10 Jul 2025 10:57:54 +0000 Subject: [PATCH] =?UTF-8?q?=E5=8D=87=E7=BA=A7=E7=BB=93=E6=9E=9C=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: jiangdi --- services/updater_main.cpp | 9 ++------- services/updater_main.h | 2 +- services/write_state/write_state.cpp | 4 ---- services/write_state/write_state.h | 1 - 4 files changed, 3 insertions(+), 13 deletions(-) diff --git a/services/updater_main.cpp b/services/updater_main.cpp index d6215055..a78ea267 100644 --- a/services/updater_main.cpp +++ b/services/updater_main.cpp @@ -1370,13 +1370,8 @@ __attribute__((weak)) void NotifyAutoReboot(PackageUpdateMode &mode) return; } -void RebootAfterUpdateSuccess(const UpdaterParams &upParams, const std::vector &args) +void RebootAfterUpdateSuccess(const UpdaterParams &upParams) { - std::string extData; - if (IsNeedUpdateNode(args, extData)) { - LOG(INFO) << "Need reboot to updater again."; - NotifyReboot("updater", "Updater update dev node after upgrade success when ptable change", extData); - } if (IsNeedWipe()) { NotifyReboot("updater", "Updater wipe data after upgrade success", "--user_wipe_data"); return; @@ -1438,7 +1433,7 @@ int UpdaterMain(int argc, char **argv) } #endif PostUpdater(true); - RebootAfterUpdateSuccess(upParams, args); + RebootAfterUpdateSuccess(upParams); return 0; } } // Updater diff --git a/services/updater_main.h b/services/updater_main.h index cea0fe3a..9cd5dcc2 100644 --- a/services/updater_main.h +++ b/services/updater_main.h @@ -35,7 +35,7 @@ int UpdaterMain(int argc, char **argv); int FactoryReset(FactoryResetMode mode, const std::string &path); -void RebootAfterUpdateSuccess(const UpdaterParams &upParams, const std::vector &args); +void RebootAfterUpdateSuccess(const UpdaterParams &upParams); UpdaterStatus InstallUpdaterPackage(UpdaterParams &upParams, Hpackage::PkgManager::PkgManagerPtr manager); diff --git a/services/write_state/write_state.cpp b/services/write_state/write_state.cpp index a5e11bf2..b98979bd 100644 --- a/services/write_state/write_state.cpp +++ b/services/write_state/write_state.cpp @@ -28,8 +28,4 @@ __attribute__((weak)) UpdaterStatus PostStartUpdaterEntry(UpdaterParams &upParam { return status; } -__attribute__((weak)) bool IsNeedUpdateNode(const std::vector &args, std::string &extData) -{ - return false; -} } // Updater diff --git a/services/write_state/write_state.h b/services/write_state/write_state.h index 86bd51a6..1a5a239d 100644 --- a/services/write_state/write_state.h +++ b/services/write_state/write_state.h @@ -28,7 +28,6 @@ extern "C" { UpdaterStatus WriteResult(std::string &path, const std::string &result); UpdaterStatus PreStartUpdaterEntry(UpdaterParams &upParams, UpdaterStatus status); UpdaterStatus PostStartUpdaterEntry(UpdaterParams &upParams, UpdaterStatus status); -bool IsNeedUpdateNode(const std::vector &args, std::string &extData); #ifdef __cplusplus #if __cplusplus } -- Gitee