diff options
Diffstat (limited to 'src/database.c')
-rw-r--r-- | src/database.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/database.c b/src/database.c index acc3acb..7a6ac8a 100644 --- a/src/database.c +++ b/src/database.c @@ -253,10 +253,8 @@ static void apk_db_diri_set(struct apk_db_dir_instance *diri, mode_t mode, static void apk_db_diri_mkdir(struct apk_db_dir_instance *diri) { - if (diri->dir->refs == 1) { - mkdir(diri->dir->dirname, diri->mode); + if (mkdir(diri->dir->dirname, diri->mode) == 0) chown(diri->dir->dirname, diri->uid, diri->gid); - } } static void apk_db_diri_rmdir(struct apk_db_dir_instance *diri) |