wuxibin89 / redis-go-cluster

redis cluster client implementation in Go
Apache License 2.0
488 stars 145 forks source link

Incorrect mapping of slot #0 #12

Closed Hamper closed 7 years ago

Hamper commented 7 years ago

slot = make([]uint16, 2) // len = 2, cap = 2 // [0, 0] slot = append(slot, uint16(start)) // [0, 0, start] slot = append(slot , uint16(end)) // [0, 0, start, end] //------------------------------------------------------ slot = make([]uint16, 0, 2) // len = 0, cap = 2 // [] slot = append(slot, uint16(start)) // [start] slot = append(slot , uint16(end)) // [start, end]