From 9e3afe0c9e830b6b5be8c58ebca820471442b64d Mon Sep 17 00:00:00 2001 From: vanhofen Date: Fri, 12 Mar 2021 20:37:06 +0100 Subject: [PATCH] move creation of /tmp/.flash.start to update code Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/c5b2772226cf9663b39b1d6c11698b1491f5d009 Author: vanhofen Date: 2021-03-12 (Fri, 12 Mar 2021) Origin message was: ------------------ - move creation of /tmp/.flash.start to update code ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- data/control/flash.start | 2 -- src/gui/update.cpp | 3 +++ src/neutrino.cpp | 6 +++++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/data/control/flash.start b/data/control/flash.start index 1cee8f724..dec5a6953 100755 --- a/data/control/flash.start +++ b/data/control/flash.start @@ -3,7 +3,5 @@ # kill start script first to ignore neutrino's exit codes killall start_neutrino -touch /tmp/.flash.start - # run shutdown routine depending on flagfile /etc/init.d/rcK diff --git a/src/gui/update.cpp b/src/gui/update.cpp index 9f42e25c4..38d62c37f 100644 --- a/src/gui/update.cpp +++ b/src/gui/update.cpp @@ -733,6 +733,9 @@ int CFlashUpdate::exec(CMenuTarget* parent, const std::string &actionKey) #ifndef DRYRUN if (flashing) { + if ( FILE *f = fopen("/tmp/.flash.start", "w") ) + fclose(f); + CVFD::getInstance()->setMode(CVFD::MODE_MENU_UTF8); CVFD::getInstance()->showMenuText(0, "ofgwrite Flashing Tool", -1, true); my_system(4, ofgwrite_caller.c_str(), g_settings.update_dir.c_str(), filename.c_str(), ofgwrite_options.c_str()); diff --git a/src/neutrino.cpp b/src/neutrino.cpp index 8b12e0303..0bed15c17 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -5345,7 +5345,11 @@ void stop_lcd4l_support() void stop_daemons(bool stopall, bool for_flash) { CMoviePlayerGui::getInstance().stopPlayBack(); - if (for_flash) { + if (for_flash) + { + if ( FILE *f = fopen("/tmp/.flash.start", "w") ) + fclose(f); + CVFD::getInstance()->Clear(); CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO); CVFD::getInstance()->ShowText("Stop daemons...");