The pstage_manualclean function can be called on a directory containing an
actively held lock on staging. Removing the lock file whilst the lock is held
results in a failure when the lock is released.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5553
311d38ba-8fff-0310-9ca6-
ca027cbcb966
for walkroot, dirs, files in os.walk(src):
for file in files:
+ # Avoid breaking the held lock
+ if (file == "staging.lock"):
+ continue
filepath = os.path.join(walkroot, file).replace(src, dest)
bb.note("rm %s" % filepath)
os.system("rm %s" % filepath)