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

dispatcher: Fix registration with length 16 IPv4 addresses #3512

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion go/lib/sock/reliable/registration.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// Copyright 2018 ETH Zurich
// Copyright 2019 ETH Zurich, Anapaya Systems
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -188,7 +189,7 @@ func (l *registrationAddressField) DecodeFromBytes(b []byte) error {
func (l *registrationAddressField) SetFromUDPAddr(u *net.UDPAddr) {
l.Port = uint16(u.Port)
l.AddressType = byte(getIPAddressType(u.IP))
l.Address = []byte(u.IP)
l.Address = normalizeIP(u.IP)
}

func (l *registrationAddressField) length() int {
Expand Down