Fix dht find value and updates from latest protocol changes #90

Merged
shyba merged 5 commits from fix_dht into master 2021-10-05 15:03:23 +02:00
3 changed files with 8 additions and 7 deletions
Showing only changes of commit 8161f48c15 - Show all commits

View file

@ -21,6 +21,7 @@ func NormalizeName(s string) string {
c := cases.Fold() c := cases.Fold()
return c.String(norm.NFD.String(s)) return c.String(norm.NFD.String(s))
} }
// ReverseBytesInPlace reverse the bytes. thanks, Satoshi 😒 // ReverseBytesInPlace reverse the bytes. thanks, Satoshi 😒
func ReverseBytesInPlace(s []byte) { func ReverseBytesInPlace(s []byte) {
for i, j := 0, len(s)-1; i < j; i, j = i+1, j-1 { for i, j := 0, len(s)-1; i < j; i, j = i+1, j-1 {