[Lldb-commits] [lldb] r160591 - /lldb/trunk/source/Interpreter/Args.cpp
Jim Ingham
jingham at apple.com
Fri Jul 20 17:12:58 PDT 2012
Author: jingham
Date: Fri Jul 20 19:12:58 2012
New Revision: 160591
URL: http://llvm.org/viewvc/llvm-project?rev=160591&view=rev
Log:
Handle backslash protection inside unquoted commands like:
(lldb) file hello\ world
correctly.
<rdar://problem/11093911>
Modified:
lldb/trunk/source/Interpreter/Args.cpp
Modified: lldb/trunk/source/Interpreter/Args.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Interpreter/Args.cpp?rev=160591&r1=160590&r2=160591&view=diff
==============================================================================
--- lldb/trunk/source/Interpreter/Args.cpp (original)
+++ lldb/trunk/source/Interpreter/Args.cpp Fri Jul 20 19:12:58 2012
@@ -230,7 +230,18 @@
break;
default:
- arg_pos = arg_end + 2;
+ if (quote_char == '\0')
+ {
+ arg.append (arg_piece_start, arg_end - arg_piece_start);
+ if (arg_end + 1 != '\0')
+ {
+ arg.append (arg_end + 1, 1);
+ arg_pos = arg_end + 2;
+ arg_piece_start = arg_pos;
+ }
+ }
+ else
+ arg_pos = arg_end + 2;
break;
}
break;
More information about the lldb-commits
mailing list