1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-31 05:04:23 +03:00

Scan: swap return values and change cursor type.

This commit is contained in:
Vladimir Mihailenco
2016-04-09 13:07:42 +03:00
parent 2add1e06fb
commit 38be24b025
5 changed files with 25 additions and 27 deletions

View File

@ -399,7 +399,7 @@ func readReply(cn *pool.Conn, p multiBulkParser) (interface{}, error) {
return nil, fmt.Errorf("redis: can't parse %.100q", line)
}
func readScanReply(cn *pool.Conn) ([]string, int64, error) {
func readScanReply(cn *pool.Conn) ([]string, uint64, error) {
n, err := readArrayHeader(cn)
if err != nil {
return nil, 0, err
@ -413,7 +413,7 @@ func readScanReply(cn *pool.Conn) ([]string, int64, error) {
return nil, 0, err
}
cursor, err := strconv.ParseInt(bytesToString(b), 10, 64)
cursor, err := strconv.ParseUint(bytesToString(b), 10, 64)
if err != nil {
return nil, 0, err
}