[Lldb-commits] [lldb] r247256 - Fix an AttributeError in dotest.py if --executable points to a wrong place

Ilia K via lldb-commits lldb-commits at lists.llvm.org
Thu Sep 10 02:24:43 PDT 2015


Author: ki.stfu
Date: Thu Sep 10 04:24:43 2015
New Revision: 247256

URL: http://llvm.org/viewvc/llvm-project?rev=247256&view=rev
Log:
Fix an AttributeError in dotest.py if --executable points to a wrong place

This patch fixes the following case:
```
  $ ./dotest.py --executable=~/p/llvm/build_ninja/bin/lldb tools/lldb-mi/
  '~/p/llvm/build_ninja/bin/lldb' is not a path to a valid executable
  Traceback (most recent call last):
    File "./dotest.py", line 1306, in <module>
      setupSysPath()
    File "./dotest.py", line 1004, in setupSysPath
      if not lldbtest_config.lldbExec:
  AttributeError: 'module' object has no attribute 'lldbExec'
```

And with this fix:
```
  $ ./dotest.py --executable=~/p/llvm/build_ninja/bin/lldb tools/lldb-mi/
  '~/p/llvm/build_ninja/bin/lldb' is not a path to a valid executable
  The 'lldb' executable cannot be located.  Some of the tests may not be run as a result.
```


Modified:
    lldb/trunk/test/dotest.py

Modified: lldb/trunk/test/dotest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dotest.py?rev=247256&r1=247255&r2=247256&view=diff
==============================================================================
--- lldb/trunk/test/dotest.py (original)
+++ lldb/trunk/test/dotest.py Thu Sep 10 04:24:43 2015
@@ -997,7 +997,7 @@ def setupSysPath():
 
     if lldbtest_config.lldbExec and not is_exe(lldbtest_config.lldbExec):
         print "'{}' is not a path to a valid executable".format(lldbtest_config.lldbExec)
-        del lldbtest_config.lldbExec
+        lldbtest_config.lldbExec = None
 
     if not lldbtest_config.lldbExec:
         print "The 'lldb' executable cannot be located.  Some of the tests may not be run as a result."




More information about the lldb-commits mailing list