summaryrefslogtreecommitdiff
path: root/wwwbin/clean-dups.py
diff options
context:
space:
mode:
Diffstat (limited to 'wwwbin/clean-dups.py')
-rwxr-xr-xwwwbin/clean-dups.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/wwwbin/clean-dups.py b/wwwbin/clean-dups.py
index 2806915..ff9d65f 100755
--- a/wwwbin/clean-dups.py
+++ b/wwwbin/clean-dups.py
@@ -50,19 +50,19 @@ ts = rpm.TransactionSet("", (rpm.RPMVSF_NOHDRCHK or rpm.RPMVSF_NEEDPAYLOAD))
def compare(f1, f2):
try:
fd1 = os.open(os.path.join(dir, f1), os.O_RDONLY)
- except Exception, e:
+ except Exception as e:
print(e)
# ignore non-files
return 0
try:
fd2 = os.open(os.path.join(dir, f2), os.O_RDONLY)
- except Exception, e:
+ except Exception as e:
print(e)
# ignore non-files
return 0
try:
h1 = ts.hdrFromFdno(fd1)
- except Exception, e:
+ except Exception as e:
print("hdrFromFdno for %s failed: %s" % (f1, e))
os.close(fd1)
os.close(fd2)
@@ -70,7 +70,7 @@ def compare(f1, f2):
try:
h2 = ts.hdrFromFdno(fd2)
- except Exception, e:
+ except Exception as e:
print("hdrFromFdno for %s failed: %s" % (f2, e))
os.close(fd1)
os.close(fd2)