Prompt the user when flash_suggest_update_bootloader()
pm3line_init() delayed to not install signal handlers on other usages than interactive client
This commit is contained in:
2 files changed
+9
-1
No files matched your search
@@ -577,6 +577,13 @@ static void flash_suggest_update_bootloader(void) {
|
||||
PrintAndLogEx(INFO, "---------------------------------------------------");
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
gs_printed_msg = true;
|
||||
if (g_session.stdinOnTTY) {
|
||||
PrintAndLogEx(INFO, "Press ENTER to continue or CTRL-C to cancel...");
|
||||
fflush(stdout);
|
||||
while (kbd_enter_pressed() == false) {
|
||||
msleep(100);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// If the device's boot is newer than the current flasher, we can suggest the user update the flasher.
|
||||
|
||||
@@ -1073,7 +1073,6 @@ int main(int argc, char *argv[]) {
|
||||
char *port = NULL;
|
||||
uint32_t speed = 0;
|
||||
|
||||
pm3line_init();
|
||||
|
||||
char exec_name[100] = {0};
|
||||
strncpy(exec_name, basename(argv[0]), sizeof(exec_name) - 1);
|
||||
@@ -1522,6 +1521,8 @@ int main(int argc, char *argv[]) {
|
||||
}
|
||||
*/
|
||||
|
||||
pm3line_init();
|
||||
|
||||
#ifdef HAVE_GUI
|
||||
|
||||
# if defined(_WIN32) || (defined(__MACH__) && defined(__APPLE__))
|
||||
|
||||
Reference in new issue
Block a user