Update OptionGroup::SetValue to take StringRef.
Then deal with all the fallout.
Differential Revision: https://reviews.llvm.org/D24847
llvm-svn: 282265
diff --git a/lldb/source/Interpreter/Options.cpp b/lldb/source/Interpreter/Options.cpp
index 8b28c6d..f8eadcc 100644
--- a/lldb/source/Interpreter/Options.cpp
+++ b/lldb/source/Interpreter/Options.cpp
@@ -913,8 +913,8 @@
Error error;
if (option_idx < m_option_infos.size()) {
error = m_option_infos[option_idx].option_group->SetOptionValue(
- m_option_infos[option_idx].option_index, option_value,
- execution_context);
+ m_option_infos[option_idx].option_index,
+ llvm::StringRef::withNullAsEmpty(option_value), execution_context);
} else {
error.SetErrorString("invalid option index"); // Shouldn't happen...