diff options
author | Alexander Larsson <alexl@redhat.com> | 2016-10-21 11:16:42 +0200 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2016-10-21 09:24:27 +0000 |
commit | cf6ec1bbbcfea78a85255a6cc4e997a6aca54e73 (patch) | |
tree | 661134f6cc801803ebed3cc16912f6506c8db998 /src/libostree/ostree-repo-checkout.c | |
parent | 64568bc706bc7d2e4d9814e0daa837b9ad84f009 (diff) | |
download | ostree-cf6ec1bbbcfea78a85255a6cc4e997a6aca54e73.tar.gz |
Fix regression for symlinks in bare-user repos
Commit 1d4f1b8878addd28059c3a3928640491755cd615 started using hardlinks
checkouts of symlinks. However, symlinks are not stored as symlink in the
repo for bare-user repos, so this breaks user-mode checkouts of such repos.
We fix this by checking for !is_symlink in the bare-user case.
This fixes:
https://github.com/ostreedev/ostree/issues/537
Closes: #538
Approved by: giuseppe
Diffstat (limited to 'src/libostree/ostree-repo-checkout.c')
-rw-r--r-- | src/libostree/ostree-repo-checkout.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libostree/ostree-repo-checkout.c b/src/libostree/ostree-repo-checkout.c index 298fcd15..9b640648 100644 --- a/src/libostree/ostree-repo-checkout.c +++ b/src/libostree/ostree-repo-checkout.c @@ -450,7 +450,9 @@ checkout_one_file_at (OstreeRepo *repo, gboolean is_bare = ((current_repo->mode == OSTREE_REPO_MODE_BARE && options->mode == OSTREE_REPO_CHECKOUT_MODE_NONE) || (current_repo->mode == OSTREE_REPO_MODE_BARE_USER - && options->mode == OSTREE_REPO_CHECKOUT_MODE_USER)); + && options->mode == OSTREE_REPO_CHECKOUT_MODE_USER + /* NOTE: bare-user symlinks are not stored as symlinks */ + && !is_symlink)); gboolean current_can_cache = (options->enable_uncompressed_cache && current_repo->enable_uncompressed_cache); gboolean is_archive_z2_with_cache = (current_repo->mode == OSTREE_REPO_MODE_ARCHIVE_Z2 |