[Apt-offline-devel] [SCM] Offline APT Package Manager branch, master, updated. 0.9.5-19-g2b1fdf4
Ritesh Raj Sarraf
rrs at researchut.com
Tue Dec 8 10:50:21 UTC 2009
The following commit has been merged in the master branch:
commit 23c4d478a394520534ddde0b9cf245d3c33e9cce
Author: Ritesh Raj Sarraf <rrs at researchut.com>
Date: Thu Dec 3 23:24:53 2009 +0530
check for APT's partial directory existence
diff --git a/AptOfflineCoreLib.py b/AptOfflineCoreLib.py
index 328ba0f..7489ed2 100644
--- a/AptOfflineCoreLib.py
+++ b/AptOfflineCoreLib.py
@@ -896,12 +896,16 @@ def installer( args ):
if not Bool_Untrusted:
AptSecure = APTVerifySigs()
- #INFO: Let's clean the partial database
- for x in os.listdir(apt_update_target_path):
- x = os.path.join(apt_update_target_path, x)
- if os.access(x, os.W_OK):
- os.unlink(x)
- log.verbose("Cleaning old update data file %s.\n" % (x) )
+ try:
+ #INFO: Let's clean the partial database
+ for x in os.listdir(apt_update_target_path):
+ x = os.path.join(apt_update_target_path, x)
+ if os.access(x, os.W_OK):
+ os.unlink(x)
+ log.verbose("Cleaning old update data file %s.\n" % (x) )
+ except OSError:
+ log.err("Cannot file APT's partial cache dir %s\n" % (apt_update_target_path) )
+ sys.exit(1)
def display_options():
--
Offline APT Package Manager
More information about the Apt-offline-devel
mailing list