tests: Protect globalLocalDrives against races (#16800)

This commit is contained in:
Klaus Post authored and GitHub committed 2023-03-13 06:04:20 -07:00
1 parent cde7eeb660
commit 628042e65e
4 files changed
+25 -2

No files matched your search

+4 -2
View File
@@ -353,8 +353,10 @@ var (
globalServiceFreezeCnt int32
globalServiceFreezeMu sync.Mutex // Updates.
// List of local drives to this node, this is only set during server startup.
globalLocalDrives []StorageAPI
// List of local drives to this node, this is only set during server startup,
// and should never be mutated. Hold globalLocalDrivesMu to access.
globalLocalDrives []StorageAPI
globalLocalDrivesMu sync.RWMutex
// Is MINIO_CI_CD set?
globalIsCICD bool