diff options
author | Tianjie Xu <xunchang@google.com> | 2017-08-29 19:51:04 +0200 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-08-29 19:51:04 +0200 |
commit | be3e19283b8852e6504daf96723b77f566fa1409 (patch) | |
tree | cbbda3734f8e94b0d246089e5eb6ec099dd6c368 /otafault/config.cpp | |
parent | Merge "Add libasyncio." am: d179c923d8 am: d21fb1ece0 am: 4dc141e6ba (diff) | |
parent | Merge "Turn on -Wall for recovery modules" am: 11f68b6b69 am: 44d0b008c6 (diff) | |
download | android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar.gz android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar.bz2 android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar.lz android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar.xz android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.tar.zst android_bootable_recovery-be3e19283b8852e6504daf96723b77f566fa1409.zip |
Diffstat (limited to 'otafault/config.cpp')
-rw-r--r-- | otafault/config.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/otafault/config.cpp b/otafault/config.cpp index 8590833ee..b94e429c6 100644 --- a/otafault/config.cpp +++ b/otafault/config.cpp @@ -69,7 +69,9 @@ std::string fault_fname(const char* io_type) { fname.resize(OTAIO_MAX_FNAME_SIZE); ZipString zip_type_path(type_path.c_str()); ZipEntry entry; - int status = FindEntry(archive, zip_type_path, &entry); + if (FindEntry(archive, zip_type_path, &entry) != 0) { + return {}; + } ExtractToMemory(archive, &entry, reinterpret_cast<uint8_t*>(&fname[0]), OTAIO_MAX_FNAME_SIZE); return fname; } |