Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4f33e55d authored by Doug Zongker's avatar Doug Zongker
Browse files

change recovery images to android with spinner

Also make writing the locale a bit more robust.

Change-Id: I803dd0aa0b9d6661fad74ea13fb085682402323c
parent 02ec6b88
Loading
Loading
Loading
Loading
+12 −9
Original line number Diff line number Diff line
@@ -277,6 +277,18 @@ finish_recovery(const char *send_intent) {
        }
    }

    // Save the locale to cache, so if recovery is next started up
    // without a --locale argument (eg, directly from the bootloader)
    // it will use the last-known locale.
    if (locale != NULL) {
        LOGI("Saving locale \"%s\"\n", locale);
        FILE* fp = fopen_path(LOCALE_FILE, "w");
        fwrite(locale, 1, strlen(locale), fp);
        fflush(fp);
        fsync(fileno(fp));
        check_and_fclose(fp, LOCALE_FILE);
    }

    // Copy logs to cache so the system can find out what happened.
    copy_log_file(TEMPORARY_LOG_FILE, LOG_FILE, true);
    copy_log_file(TEMPORARY_LOG_FILE, LAST_LOG_FILE, false);
@@ -286,15 +298,6 @@ finish_recovery(const char *send_intent) {
    chmod(LAST_LOG_FILE, 0640);
    chmod(LAST_INSTALL_FILE, 0644);

    // Save the locale to cache, so if recovery is next started up
    // without a --locale argument (eg, directly from the bootloader)
    // it will use the last-known locale.
    if (locale != NULL) {
        FILE* fp = fopen(LOCALE_FILE, "w");
        fwrite(locale, 1, strlen(locale), fp);
        fclose(fp);
    }

    // Reset to normal system boot so recovery won't cycle indefinitely.
    struct bootloader_message boot;
    memset(&boot, 0, sizeof(boot));
−1.04 KiB (17.8 KiB)
Loading image diff...
−4.09 KiB (20.6 KiB)
Loading image diff...
−2.03 KiB (7.83 KiB)
Loading image diff...
−2.14 KiB (7.62 KiB)
Loading image diff...
Loading