diff options
author | Timo Teräs <timo.teras@iki.fi> | 2014-10-07 13:29:34 +0300 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2014-10-07 14:11:29 +0300 |
commit | 09e48d8f06bfb924b80ce3e95c281524c4891828 (patch) | |
tree | b3da94f56dc065577baa06e0f3d8cd43d2500bf8 /src/commit.c | |
parent | e0f9b0897be8e5524eaeef302249c90498d3218a (diff) | |
download | apk-tools-09e48d8f06bfb924b80ce3e95c281524c4891828.tar.gz apk-tools-09e48d8f06bfb924b80ce3e95c281524c4891828.tar.bz2 apk-tools-09e48d8f06bfb924b80ce3e95c281524c4891828.tar.xz apk-tools-09e48d8f06bfb924b80ce3e95c281524c4891828.zip |
db: rework directory permission handling
Apk used to reset directory permissions always, but this is undesirable
if user has modified the permissions - especially during tmpfs boot.
Though, it is desirable to update the permissions when packaging has
changed permissions, or a new package is installed and the merged
permission mask / owner changes.
Thus the new code updates the permissions only if:
1) We are booting and directory is not in apkovl
2) The directory is modified by a package install/remove/upgrade
3) The filesystem directory permission matched database
Additionally "apk fix --directory-permissions" can be used to reset
all directory permissions to the database defaults.
Fixes #2966
Diffstat (limited to 'src/commit.c')
-rw-r--r-- | src/commit.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/commit.c b/src/commit.c index bf3b4a2..5b47d9e 100644 --- a/src/commit.c +++ b/src/commit.c @@ -302,6 +302,7 @@ int apk_solver_commit_changeset(struct apk_database *db, apk_print_progress(prog.total.bytes + prog.total.packages, prog.total.bytes + prog.total.packages); + apk_db_update_directory_permissions(db); run_triggers(db, changeset); all_done: |