Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crashing because of runtime error: slice bounds out of range #1

Open
dilipgup opened this issue Oct 29, 2019 · 0 comments
Open

Crashing because of runtime error: slice bounds out of range #1

dilipgup opened this issue Oct 29, 2019 · 0 comments

Comments

@dilipgup
Copy link

stack trace:

panic: runtime error: slice bounds out of range

goroutine 195 [running]:
panic(0x100f260, 0x1b20870)
/var/tmp/godownload/install/go/src/runtime/panic.go:551 +0x3c1 fp=0xc4210ec210 sp=0xc4210ec170 pc=0x43d331
runtime.panicslice()
/var/tmp/godownload/install/go/src/runtime/panic.go:35 +0x5e fp=0xc4210ec230 sp=0xc4210ec210 pc=0x43c04e
arubanetworks.com/vendor/github.com/kkdai/consistent.(*ConsistentHashing).hasKey(0xc420438d50, 0xc420daa770, 0x64, 0x0)
github.com/kkdai/consistent/consistent.go:126 +0x9e fp=0xc4210ec268 sp=0xc4210ec230 pc=0xd0b57e
arubanetworks.com/vendor/github.com/kkdai/consistent.(*ConsistentHashing).searchNearRingIndex(0xc420438d50, 0xc420daa770, 0x64, 0x422ba9)
github.com/kkdai/consistent/consistent.go:99 +0x43 fp=0xc4210ec2b0 sp=0xc4210ec268 pc=0xd0b293
arubanetworks.com/vendor/github.com/kkdai/consistent.(*ConsistentHashing).Get(0xc420438d50, 0xc420daa770, 0x64, 0xc4210ec368, 0x48252c, 0x1b22010, 0xc420468900)
github.com/kkdai/consistent/consistent.go:42 +0xba fp=0xc4210ec2e8 sp=0xc4210ec2b0 pc=0xd0ac3a

it's because of hasKey don't hvae protection against strings larger than 64 bytes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant