Skip to content

Commit 5d35273

Browse files
authored
[lldb] fix release build (llvm#68979)
due to 64d78d8 that used side effects in assert()
1 parent dbb9fae commit 5d35273

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

lldb/source/Commands/CommandObjectTarget.cpp

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2682,12 +2682,14 @@ class CommandObjectTargetModulesDumpSeparateDebugInfoFiles
26822682
llvm::StringRef type;
26832683
llvm::StringRef symfile;
26842684
StructuredData::Array *files;
2685-
assert(separate_debug_info_list->GetValueForKeyAsString("type",
2686-
type));
2687-
assert(separate_debug_info_list->GetValueForKeyAsString("symfile",
2688-
symfile));
2689-
assert(separate_debug_info_list->GetValueForKeyAsArray(
2690-
"separate-debug-info-files", files));
2685+
if (!(separate_debug_info_list->GetValueForKeyAsString("type",
2686+
type) &&
2687+
separate_debug_info_list->GetValueForKeyAsString("symfile",
2688+
symfile) &&
2689+
separate_debug_info_list->GetValueForKeyAsArray(
2690+
"separate-debug-info-files", files))) {
2691+
assert(false);
2692+
}
26912693

26922694
strm << "Symbol file: " << symfile;
26932695
strm.EOL();

0 commit comments

Comments
 (0)