[llvm-commits] [LNT] r155709 - /lnt/trunk/lnt/tests/compile.py
Daniel Dunbar
daniel at zuster.org
Fri Apr 27 09:06:00 PDT 2012
Author: ddunbar
Date: Fri Apr 27 11:06:00 2012
New Revision: 155709
URL: http://llvm.org/viewvc/llvm-project?rev=155709&view=rev
Log:
lnt.tests.compile: Another tweak to command line quoting.
Modified:
lnt/trunk/lnt/tests/compile.py
Modified: lnt/trunk/lnt/tests/compile.py
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/tests/compile.py?rev=155709&r1=155708&r2=155709&view=diff
==============================================================================
--- lnt/trunk/lnt/tests/compile.py (original)
+++ lnt/trunk/lnt/tests/compile.py Fri Apr 27 11:06:00 2012
@@ -21,9 +21,8 @@
def args_to_quoted_string(args):
def quote_arg(arg):
- if "'" in arg:
- return '"%s"' % arg.replace('(', '\\(')\
- .replace(')', '\\)')
+ if "'" in arg or '(' in arg or ')' in arg:
+ return '"%s"' % arg
elif '"' in arg or ' ' in arg:
return "'%s'" % arg
return arg
More information about the llvm-commits
mailing list