diff options
Diffstat (limited to 'bitbake/lib/bb/utils.py')
-rw-r--r-- | bitbake/lib/bb/utils.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py index b8b90df8d3..92d44c5260 100644 --- a/bitbake/lib/bb/utils.py +++ b/bitbake/lib/bb/utils.py | |||
@@ -431,12 +431,14 @@ def better_eval(source, locals, extraglobals = None): | |||
431 | return eval(source, ctx, locals) | 431 | return eval(source, ctx, locals) |
432 | 432 | ||
433 | @contextmanager | 433 | @contextmanager |
434 | def fileslocked(files): | 434 | def fileslocked(files, *args, **kwargs): |
435 | """Context manager for locking and unlocking file locks.""" | 435 | """Context manager for locking and unlocking file locks.""" |
436 | locks = [] | 436 | locks = [] |
437 | if files: | 437 | if files: |
438 | for lockfile in files: | 438 | for lockfile in files: |
439 | locks.append(bb.utils.lockfile(lockfile)) | 439 | l = bb.utils.lockfile(lockfile, *args, **kwargs) |
440 | if l is not None: | ||
441 | locks.append(l) | ||
440 | 442 | ||
441 | try: | 443 | try: |
442 | yield | 444 | yield |