diff options
author | Timo Teras <timo.teras@iki.fi> | 2009-12-21 16:53:47 +0200 |
---|---|---|
committer | Timo Teras <timo.teras@iki.fi> | 2009-12-21 16:53:47 +0200 |
commit | 6417de4d1057675bacc06274cab385810b86eed7 (patch) | |
tree | 3ac64f217deadd9acd12d5de6cdf665a36086baa /src/database.c | |
parent | f44f34811dde4e33210e83af8584a99543d528a8 (diff) | |
download | apk-tools-6417de4d1057675bacc06274cab385810b86eed7.tar.gz apk-tools-6417de4d1057675bacc06274cab385810b86eed7.tar.bz2 apk-tools-6417de4d1057675bacc06274cab385810b86eed7.tar.xz apk-tools-6417de4d1057675bacc06274cab385810b86eed7.zip |
apk: remove the unneeded --never-overwrite
turns out the logic does not work with overlays as expected due
to busybox symlinks being unmanaged. remove the useless option.
Diffstat (limited to 'src/database.c')
-rw-r--r-- | src/database.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/database.c b/src/database.c index fef25f8..debe897 100644 --- a/src/database.c +++ b/src/database.c @@ -1942,11 +1942,9 @@ static void apk_db_migrate_files(struct apk_database *db, apk_checksum_compare(&file->csum, &fi.csum) == 0)) unlinkat(db->root_fd, tmpname, 0); } else { - /* check if want keep existing files */ - if ((ofile->name == NULL) || - ((apk_flags & APK_NEVER_OVERWRITE) && - (faccessat(db->root_fd, name, F_OK, - AT_SYMLINK_NOFOLLOW) == 0))) { + if (ofile->name == NULL) { + /* File was from overlay, delete the + * packages version */ unlinkat(db->root_fd, tmpname, 0); } else { /* Overwrite the old file */ |