From 78850b1a68427ca5459b667f50c64709db21c4c2 Mon Sep 17 00:00:00 2001 From: Soramichi Akiyama Date: Sat, 6 Jun 2015 16:23:12 +0900 Subject: packet: fix PathAttributeAs4Aggregator serialization --- packet/bgp.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'packet/bgp.go') diff --git a/packet/bgp.go b/packet/bgp.go index bd9cefa6..c745effa 100644 --- a/packet/bgp.go +++ b/packet/bgp.go @@ -3356,7 +3356,7 @@ func (p *PathAttributeAs4Aggregator) DecodeFromBytes(data []byte) error { func (p *PathAttributeAs4Aggregator) Serialize() ([]byte, error) { buf := make([]byte, 8) binary.BigEndian.PutUint32(buf[0:], p.Value.AS) - copy(buf[4:], p.Value.Address) + copy(buf[4:], p.Value.Address.To4()) p.PathAttribute.Value = buf return p.PathAttribute.Serialize() } -- cgit v1.2.3