[Lldb-commits] [lldb] r237946 - Don't import module `lock` at global scope.

Vince Harron vince at nethacker.com
Thu May 21 13:53:02 PDT 2015


Sorry for the break, thanks for the fix/lesson.

On Thu, May 21, 2015 at 1:16 PM, Zachary Turner <zturner at google.com> wrote:

> Author: zturner
> Date: Thu May 21 15:16:02 2015
> New Revision: 237946
>
> URL: http://llvm.org/viewvc/llvm-project?rev=237946&view=rev
> Log:
> Don't import module `lock` at global scope.
>
> `lock` depends on `fcntl`, which doesn't exist on Windows.  Until
> someone implements an equivalent locking mechanism on Windows, we
> can't have lock imported globally.
>
> 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=237946&r1=237945&r2=237946&view=diff
>
> ==============================================================================
> --- lldb/trunk/test/lldbtest.py (original)
> +++ lldb/trunk/test/lldbtest.py Thu May 21 15:16:02 2015
> @@ -33,7 +33,6 @@ $
>
>  import abc
>  import glob
> -import lock
>  import os, sys, traceback
>  import os.path
>  import re
> @@ -961,6 +960,7 @@ class Base(unittest2.TestCase):
>              os.chdir(os.path.join(os.environ["LLDB_TEST"], cls.mydir))
>
>          if debug_confirm_directory_exclusivity:
> +            import lock
>              cls.dir_lock = lock.Lock(os.path.join(full_dir, ".dirlock"))
>              try:
>                  cls.dir_lock.try_acquire()
>
>
> _______________________________________________
> lldb-commits mailing list
> lldb-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150521/009b532d/attachment.html>


More information about the lldb-commits mailing list