mirror of
https://github.com/redis/go-redis.git
synced 2025-10-17 11:11:17 +03:00
fix: add missing error variable for non-unix build constraints (#3538)
* fix: add missing error variable for non-unix build constraints * chore: name "_" for unused parameters --------- Co-authored-by: Elena Kolevska <elena-kolevska@users.noreply.github.com>
This commit is contained in:
@@ -2,13 +2,19 @@
|
||||
|
||||
package pool
|
||||
|
||||
import "net"
|
||||
import (
|
||||
"errors"
|
||||
"net"
|
||||
)
|
||||
|
||||
func connCheck(conn net.Conn) error {
|
||||
// errUnexpectedRead is placeholder error variable for non-unix build constraints
|
||||
var errUnexpectedRead = errors.New("unexpected read from socket")
|
||||
|
||||
func connCheck(_ net.Conn) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// since we can't check for data on the socket, we just assume there is some
|
||||
func maybeHasData(conn net.Conn) bool {
|
||||
func maybeHasData(_ net.Conn) bool {
|
||||
return true
|
||||
}
|
||||
|
Reference in New Issue
Block a user