From d44a35e87e405ae98902dc491ba70ed82f58f592 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 20 Apr 2017 21:21:28 +0000 Subject: Vendor import of lldb trunk r300890: https://llvm.org/svn/llvm-project/lldb/trunk@300890 --- source/Interpreter/CommandHistory.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/Interpreter/CommandHistory.cpp') diff --git a/source/Interpreter/CommandHistory.cpp b/source/Interpreter/CommandHistory.cpp index 0fa25ed806ff..ca5c90692b6a 100644 --- a/source/Interpreter/CommandHistory.cpp +++ b/source/Interpreter/CommandHistory.cpp @@ -47,13 +47,13 @@ CommandHistory::FindString(llvm::StringRef input_str) const { size_t idx = 0; if (input_str.front() == '-') { - if (input_str.drop_front(2).getAsInteger(0, idx)) + if (input_str.drop_front(1).getAsInteger(0, idx)) return llvm::None; if (idx >= m_history.size()) return llvm::None; idx = m_history.size() - idx; } else { - if (input_str.drop_front().getAsInteger(0, idx)) + if (input_str.getAsInteger(0, idx)) return llvm::None; if (idx >= m_history.size()) return llvm::None; -- cgit v1.3