simplify usage of mutexes and atomic constants (#9501)

This commit is contained in:
Harshavardhana
2020-05-03 22:35:40 -07:00
committed by GitHub
parent fbd15cb7b7
commit 27d716c663
18 changed files with 419 additions and 305 deletions
+2 -2
View File
@@ -78,7 +78,7 @@ func TestGetCachedLoc(t *testing.T) {
// find cache drive where object would be hashed
index := c.hashIndex(bucketName, objectName)
// turn off drive by setting online status to false
c.cache[index].online = false
c.cache[index].setOffline()
cfs, err := c.getCacheLoc(bucketName, objectName)
if n == 1 && err == errDiskNotFound {
continue
@@ -118,7 +118,7 @@ func TestGetCacheMaxUse(t *testing.T) {
// find cache drive where object would be hashed
index := c.hashIndex(bucketName, objectName)
// turn off drive by setting online status to false
c.cache[index].online = false
c.cache[index].setOffline()
cb, err := c.getCacheLoc(bucketName, objectName)
if n == 1 && err == errDiskNotFound {
continue