summaryrefslogtreecommitdiff
path: root/src/database.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/database.c')
-rw-r--r--src/database.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/database.c b/src/database.c
index 58c00d4..3b5bc38 100644
--- a/src/database.c
+++ b/src/database.c
@@ -1726,10 +1726,12 @@ int apk_db_open(struct apk_database *db, struct apk_db_options *dbopts)
}
}
- if (!(dbopts->open_flags & APK_OPENF_NO_SYS_REPOS)) {
+ if (!(dbopts->open_flags & APK_OPENF_NO_CMDLINE_REPOS)) {
list_for_each_entry(repo, &dbopts->repository_list, list)
apk_db_add_repository(db, APK_BLOB_STR(repo->url));
+ }
+ if (!(dbopts->open_flags & APK_OPENF_NO_SYS_REPOS)) {
if (dbopts->repositories_file == NULL) {
add_repos_from_file(db, db->root_fd, "etc/apk/repositories");
apk_dir_foreach_file(openat(db->root_fd, "etc/apk/repositories.d", O_RDONLY | O_CLOEXEC),