diff --git a/fastboot/device/fastboot_device.cpp b/fastboot/device/fastboot_device.cpp index 6b6a9820e..0dc4e9764 100644 --- a/fastboot/device/fastboot_device.cpp +++ b/fastboot/device/fastboot_device.cpp @@ -151,7 +151,8 @@ std::string FastbootDevice::GetCurrentSlot() { } BootControlClient* FastbootDevice::boot1_1() const { - if (boot_control_hal_->GetVersion() >= android::hal::BootControlVersion::BOOTCTL_V1_1) { + if (boot_control_hal_ && + boot_control_hal_->GetVersion() >= android::hal::BootControlVersion::BOOTCTL_V1_1) { return boot_control_hal_.get(); } return nullptr;