go.net/ipv4: add Flags field to Header
Fixes golang/go#6453.
R=golang-dev, mikioh.mikioh
CC=golang-dev
https://golang.org/cl/13832043
diff --git a/ipv4/header_test.go b/ipv4/header_test.go
index cc2fd8e..121d1f2 100644
--- a/ipv4/header_test.go
+++ b/ipv4/header_test.go
@@ -16,28 +16,28 @@
var (
wireHeaderFromKernel = [ipv4.HeaderLen]byte{
0x45, 0x01, 0xbe, 0xef,
- 0xca, 0xfe, 0x05, 0xdc,
+ 0xca, 0xfe, 0x45, 0xdc,
0xff, 0x01, 0xde, 0xad,
172, 16, 254, 254,
192, 168, 0, 1,
}
wireHeaderToKernel = [ipv4.HeaderLen]byte{
0x45, 0x01, 0xbe, 0xef,
- 0xca, 0xfe, 0x05, 0xdc,
+ 0xca, 0xfe, 0x45, 0xdc,
0xff, 0x01, 0xde, 0xad,
172, 16, 254, 254,
192, 168, 0, 1,
}
wireHeaderFromTradBSDKernel = [ipv4.HeaderLen]byte{
0x45, 0x01, 0xdb, 0xbe,
- 0xca, 0xfe, 0xdc, 0x05,
+ 0xca, 0xfe, 0xdc, 0x45,
0xff, 0x01, 0xde, 0xad,
172, 16, 254, 254,
192, 168, 0, 1,
}
wireHeaderToTradBSDKernel = [ipv4.HeaderLen]byte{
0x45, 0x01, 0xef, 0xbe,
- 0xca, 0xfe, 0xdc, 0x05,
+ 0xca, 0xfe, 0xdc, 0x45,
0xff, 0x01, 0xde, 0xad,
172, 16, 254, 254,
192, 168, 0, 1,
@@ -51,6 +51,7 @@
TOS: 1,
TotalLen: 0xbeef,
ID: 0xcafe,
+ Flags: ipv4.DontFragment,
FragOff: 1500,
TTL: 255,
Protocol: 1,