aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--MgaRepo/rpmutil.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/MgaRepo/rpmutil.py b/MgaRepo/rpmutil.py
index 62c486d..2f07845 100644
--- a/MgaRepo/rpmutil.py
+++ b/MgaRepo/rpmutil.py
@@ -562,7 +562,8 @@ def sync(dryrun=False, commit=False, download=False):
status = sourcesst.get(entry)
path = os.path.join(sourcesdir, entry)
if entry not in sources:
- toremove.append(path)
+ if os.path.islink(path) or status is None:
+ toremove.append(path)
for path in toremove:
print "D\t%s" % path
if not dryrun: