pld-ftp-admin: modules/ftptree.py - do not allow removal if buildi...

mmazur mmazur at pld-linux.org
Thu Jul 21 18:19:02 CEST 2005


Author: mmazur                       Date: Thu Jul 21 16:19:02 2005 GMT
Module: pld-ftp-admin                 Tag: HEAD
---- Log message:
- do not allow removal if building not finished

---- Files affected:
pld-ftp-admin/modules:
   ftptree.py (1.18 -> 1.19) 

---- Diffs:

================================================================
Index: pld-ftp-admin/modules/ftptree.py
diff -u pld-ftp-admin/modules/ftptree.py:1.18 pld-ftp-admin/modules/ftptree.py:1.19
--- pld-ftp-admin/modules/ftptree.py:1.18	Thu Jul 14 21:34:32 2005
+++ pld-ftp-admin/modules/ftptree.py	Thu Jul 21 18:18:56 2005
@@ -151,6 +151,9 @@
             pkg.move(dsttree)
 
     def removepkgs(self):
+        if self.do_checkbuild:
+            self.__checkbuild()
+        bailoutonerror()
         for pkg in self.marked4removal:
             pkg.remove()
 
@@ -202,7 +205,12 @@
             elif i[0]=='b':
                 requests[id]=requests[id]+i
         f.close()
-        for pkg in self.marked4moving:
+        marked=[]
+        if self.marked4moving:
+            marked=self.marked4moving
+        elif self.marked4removal:
+            marked=self.marked4removal
+        for pkg in marked:
             for bid in pkg.build.keys():
                 if requests.has_key(bid) and not requests[bid].find('?') == -1:
                     perror("%s (buildid %s) building not finished" % (pkg,bid))
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/pld-ftp-admin/modules/ftptree.py?r1=1.18&r2=1.19&f=u




More information about the pld-cvs-commit mailing list