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

Commit 093a8cb3 authored by David Anderson's avatar David Anderson Committed by android-build-merger
Browse files

Merge "boot_control: Don't allow current_slot_ to be -1." am: 9c0f1028 am:...

Merge "boot_control: Don't allow current_slot_ to be -1." am: 9c0f1028 am: 0c34ef80 am: 18501341
am: 569f587a

Change-Id: I9b10028dbcc474cee42bd080d25fdab598ef431c
parents b98955fe 569f587a
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -196,6 +196,10 @@ bool BootControl::Init() {
  // was not set (from either the command line or the device tree), we can later
  // initialize it from the bootloader_control struct.
  std::string suffix_prop = android::base::GetProperty("ro.boot.slot_suffix", "");
  if (suffix_prop.empty()) {
    LOG(ERROR) << "Slot suffix property is not set";
    return false;
  }
  current_slot_ = SlotSuffixToIndex(suffix_prop.c_str());

  std::string err;