Skip to content

Commit

Permalink
Fixed an issue where having local files database would case a crash
Browse files Browse the repository at this point in the history
  • Loading branch information
Remedan committed Feb 21, 2018
1 parent 4ef0a5c commit 305a652
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions vrms
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ h = pyalpm.Handle("/", "/var/lib/pacman")
dbs_to_visit = []

if(options.use_global_repos):
for d in os.listdir("/var/lib/pacman/sync"):
h.register_syncdb(os.path.splitext(d)[0], 0)
for d in set(os.path.splitext(f)[0] for f in os.listdir("/var/lib/pacman/sync")):
h.register_syncdb(d, 0)
dbs_to_visit = h.get_syncdbs()
else:
# print("There are %d installed packages." % len(h.get_localdb()))
Expand Down

0 comments on commit 305a652

Please sign in to comment.