commit | 932fe519f60dfb3346926b61a28f633fec8c4ad6 | [log] [tgz] |
---|---|---|
author | Arun Sharma <arsharma@google.com> | Thu Oct 05 18:16:09 2023 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Thu Oct 05 18:16:09 2023 +0000 |
tree | 0e6db3e3df92ddc743155ccc3b09ac68c042617e | |
parent | 5c3edb098ac9d8141c4d8a076aa3c32a9f8e74d8 [diff] | |
parent | 828d85ae89da53a1362a34d5e65e5334943efdb2 [diff] |
Merge "FastbootDevice::boot1_1 null pointer dereference" into main am: 608e33f736 am: 828d85ae89 Original change: https://android-review.googlesource.com/c/platform/system/core/+/2768099 Change-Id: I205dca350682e9ae709838db645c229c978ebb12 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/fastboot/device/fastboot_device.cpp b/fastboot/device/fastboot_device.cpp index 6b6a982..0dc4e97 100644 --- a/fastboot/device/fastboot_device.cpp +++ b/fastboot/device/fastboot_device.cpp
@@ -151,7 +151,8 @@ } 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;