summaryrefslogtreecommitdiffstats
path: root/otafault/config.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'otafault/config.cpp')
-rw-r--r--otafault/config.cpp4
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;
}