1
0
Fork 0
mirror of https://github.com/restic/restic.git synced 2025-03-09 00:00:02 +01:00

repository/repository - fix unused sync.Mutex m

This commit is contained in:
Winfried Plappert 2025-03-05 22:15:27 +00:00
parent 8e71a92976
commit d794e41252

View file

@ -54,7 +54,6 @@ type Repository struct {
maxRepoCapReached bool
maxRepoMutex sync.Mutex
}
// internalRepository allows using SaveUnpacked and RemoveUnpacked with all FileTypes
@ -399,8 +398,6 @@ func (r *Repository) saveAndEncrypt(ctx context.Context, t restic.BlobType, data
length, err := pm.SaveBlob(ctx, t, id, ciphertext, uncompressedLength)
var m sync.Mutex
// maximum repository capacity exceeded?
r.maxRepoMutex.Lock()
defer r.maxRepoMutex.Unlock()