diff options
| author | kat <kat@vector35.com> | 2025-02-04 13:09:59 -0500 |
|---|---|---|
| committer | kat <kat@vector35.com> | 2025-02-04 13:09:59 -0500 |
| commit | d6856d77526cddf915e235a5842f2e57c8b33284 (patch) | |
| tree | 916385cffe4d37cb2cd0b163553078ec4c12400a /view/sharedcache/core/DSCView.cpp | |
| parent | ed08160e6782b3f8b371370bfad3a04e80e94f4d (diff) | |
Avoid crashing when initial type parse fails in DSCView
Diffstat (limited to 'view/sharedcache/core/DSCView.cpp')
| -rw-r--r-- | view/sharedcache/core/DSCView.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/view/sharedcache/core/DSCView.cpp b/view/sharedcache/core/DSCView.cpp index 92fe2227..c0b7b349 100644 --- a/view/sharedcache/core/DSCView.cpp +++ b/view/sharedcache/core/DSCView.cpp @@ -180,6 +180,12 @@ bool DSCView::Init() "\t\tuint32_t tproMappingsCount; // number of dyld_cache_tpro_mapping_info entries\n" "\t};", headerType, err); + if (!err.empty() || !headerType.type) + { + LogError("Failed to parse header type: %s", err.c_str()); + return false; + } + Ref<Settings> settings = GetLoadSettings(GetTypeName()); if (!settings) |
