From: Zac Medico Date: Sat, 3 Mar 2007 21:42:46 +0000 (-0000) Subject: Pass waiting_msg into recursive lockfile() calls. X-Git-Tag: v2.2_pre1~1614 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d042ce847d7fef4fa45030cf16f1a09c736578ef;p=portage.git Pass waiting_msg into recursive lockfile() calls. svn path=/main/trunk/; revision=6156 --- diff --git a/pym/portage/locks.py b/pym/portage/locks.py index cbf7ee4b5..167109432 100644 --- a/pym/portage/locks.py +++ b/pym/portage/locks.py @@ -53,7 +53,8 @@ def lockfile(mypath, wantnewlockfile=0, unlinkfile=0, waiting_msg=None): os.chown(lockfilename,os.getuid(),portage_gid) except OSError, e: if e[0] == 2: # No such file or directory - return lockfile(mypath,wantnewlockfile,unlinkfile) + return lockfile(mypath, wantnewlockfile=wantnewlockfile, + unlinkfile=unlinkfile, waiting_msg=waiting_msg) else: writemsg("Cannot chown a lockfile. This could cause inconvenience later.\n"); os.umask(old_mask) @@ -110,7 +111,9 @@ def lockfile(mypath, wantnewlockfile=0, unlinkfile=0, waiting_msg=None): # The file was deleted on us... Keep trying to make one... os.close(myfd) writemsg("lockfile recurse\n",1) - lockfilename,myfd,unlinkfile,locking_method = lockfile(mypath,wantnewlockfile,unlinkfile) + lockfilename, myfd, unlinkfile, locking_method = lockfile( + mypath, wantnewlockfile=wantnewlockfile, unlinkfile=unlinkfile, + waiting_msg=waiting_msg) writemsg(str((lockfilename,myfd,unlinkfile))+"\n",1) return (lockfilename,myfd,unlinkfile,locking_method)