diff options
Diffstat (limited to 'dhcpv6/option_nii.go')
-rw-r--r-- | dhcpv6/option_nii.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/dhcpv6/option_nii.go b/dhcpv6/option_nii.go index 1df1579..85c9d4b 100644 --- a/dhcpv6/option_nii.go +++ b/dhcpv6/option_nii.go @@ -39,10 +39,10 @@ func (op *OptNetworkInterfaceId) Code() OptionCode { func (op *OptNetworkInterfaceId) ToBytes() []byte { buf := make([]byte, 7) binary.BigEndian.PutUint16(buf[0:2], uint16(OPTION_NII)) - binary.BigEndian.PutUint16(buf[2:5], uint16(op.Length())) - buf[5] = op.type_ - buf[6] = op.major - buf[7] = op.minor + binary.BigEndian.PutUint16(buf[2:4], uint16(op.Length())) + buf[4] = op.type_ + buf[5] = op.major + buf[6] = op.minor return buf } |