1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-29 17:41:15 +03:00

fix(internal/pool): call SetDeadline even if timeout is zero

This commit is contained in:
jianghang
2022-08-03 22:43:37 +08:00
parent 084c0c8914
commit 2123e08437
2 changed files with 5 additions and 9 deletions

View File

@ -76,7 +76,7 @@ type Options struct {
// Default is 3 seconds.
ReadTimeout time.Duration
// Timeout for socket writes. If reached, commands will fail
// with a timeout instead of blocking.
// with a timeout instead of blocking. Use value -1 for no timeout and 0 for default.
// Default is ReadTimeout.
WriteTimeout time.Duration