From 7fa57ee5798c878faef9a56847ce53420958cce3 Mon Sep 17 00:00:00 2001 From: Tamir Duberstein Date: Fri, 21 Sep 2018 12:06:27 -0700 Subject: Export read-only tcpip.Subnet.Mask PiperOrigin-RevId: 214023383 Change-Id: I5a7572f949840fb68a3ffb7342e6a3524bd00864 --- pkg/tcpip/tcpip.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'pkg') diff --git a/pkg/tcpip/tcpip.go b/pkg/tcpip/tcpip.go index b1bd5117f..a5259341b 100644 --- a/pkg/tcpip/tcpip.go +++ b/pkg/tcpip/tcpip.go @@ -202,6 +202,11 @@ func (s *Subnet) Prefix() int { return len(s.mask) * 8 } +// Mask returns the subnet mask. +func (s *Subnet) Mask() AddressMask { + return s.mask +} + // NICID is a number that uniquely identifies a NIC. type NICID int32 -- cgit v1.2.3