[Lldb-commits] [lldb] r242576 - Check if altsep exists before replace.

Chaoren Lin chaorenl at google.com
Fri Jul 17 14:40:11 PDT 2015


Author: chaoren
Date: Fri Jul 17 16:40:11 2015
New Revision: 242576

URL: http://llvm.org/viewvc/llvm-project?rev=242576&view=rev
Log:
Check if altsep exists before replace.

Modified:
    lldb/trunk/test/lldbtest.py

Modified: lldb/trunk/test/lldbtest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/lldbtest.py?rev=242576&r1=242575&r2=242576&view=diff
==============================================================================
--- lldb/trunk/test/lldbtest.py (original)
+++ lldb/trunk/test/lldbtest.py Fri Jul 17 16:40:11 2015
@@ -1651,7 +1651,8 @@ class Base(unittest2.TestCase):
 
         if compiler[1] == ':':
             compiler = compiler[2:]
-        compiler = compiler.replace(os.path.altsep, os.path.sep)
+        if os.path.altsep is not None:
+            compiler = compiler.replace(os.path.altsep, os.path.sep)
 
         fname = "{}-{}-{}".format(self.id(), self.getArchitecture(), "_".join(compiler.split(os.path.sep)))
         if len(fname) > 200:





More information about the lldb-commits mailing list