(fam byte)
| 39 | } |
| 40 | |
| 41 | func (e *Reject) marshalData(fam byte) ([]byte, error) { |
| 42 | return netlink.MarshalAttributes([]netlink.Attribute{ |
| 43 | {Type: unix.NFTA_REJECT_TYPE, Data: binaryutil.BigEndian.PutUint32(e.Type)}, |
| 44 | {Type: unix.NFTA_REJECT_ICMP_CODE, Data: []byte{e.Code}}, |
| 45 | }) |
| 46 | } |
| 47 | |
| 48 | func (e *Reject) unmarshal(fam byte, data []byte) error { |
| 49 | ad, err := netlink.NewAttributeDecoder(data) |