aboutsummaryrefslogtreecommitdiff
path: root/src/libstore
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2020-12-13 13:39:20 +0100
committerGitHub <noreply@github.com>2020-12-13 13:39:20 +0100
commit92438c70d2291a02577e02b9462f53c23817aebd (patch)
tree2d8e774c89130c352cb23912fbf98c328ebc81b8 /src/libstore
parent9c143c411b2190a05907416266b0022e5b17dd02 (diff)
parent63b3536f50f124cdcd7592b344eac157a1439d42 (diff)
Merge pull request #4352 from jonringer/allow-private-caches
treat s3 permission errors as file-not-found
Diffstat (limited to 'src/libstore')
-rw-r--r--src/libstore/s3-binary-cache-store.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libstore/s3-binary-cache-store.cc b/src/libstore/s3-binary-cache-store.cc
index 27253fc12..d6edafd7e 100644
--- a/src/libstore/s3-binary-cache-store.cc
+++ b/src/libstore/s3-binary-cache-store.cc
@@ -166,7 +166,8 @@ S3Helper::FileTransferResult S3Helper::getObject(
dynamic_cast<std::stringstream &>(result.GetBody()).str());
} catch (S3Error & e) {
- if (e.err != Aws::S3::S3Errors::NO_SUCH_KEY) throw;
+ if ((e.err != Aws::S3::S3Errors::NO_SUCH_KEY) &&
+ (e.err != Aws::S3::S3Errors::ACCESS_DENIED)) throw;
}
auto now2 = std::chrono::steady_clock::now();