mirror of
https://github.com/minio/minio.git
synced 2024-12-24 06:05:55 -05:00
fix: a cosmetic error reporting with a lock timeout (#16788)
This commit is contained in:
parent
a547bf517d
commit
5c087bdcad
@ -170,7 +170,7 @@ func (di *distLockInstance) GetLock(ctx context.Context, timeout *dynamicTimeout
|
||||
RetryInterval: timeout.RetryInterval(),
|
||||
}) {
|
||||
timeout.LogFailure()
|
||||
cancel()
|
||||
defer cancel()
|
||||
if err := newCtx.Err(); err == context.Canceled {
|
||||
return LockContext{ctx: ctx, cancel: func() {}}, err
|
||||
}
|
||||
@ -199,7 +199,7 @@ func (di *distLockInstance) GetRLock(ctx context.Context, timeout *dynamicTimeou
|
||||
RetryInterval: timeout.RetryInterval(),
|
||||
}) {
|
||||
timeout.LogFailure()
|
||||
cancel()
|
||||
defer cancel()
|
||||
if err := newCtx.Err(); err == context.Canceled {
|
||||
return LockContext{ctx: ctx, cancel: func() {}}, err
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user