summaryrefslogtreecommitdiff
path: root/vendor/github.com/vishvananda/netlink/conntrack_linux.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-01-11 05:39:12 -0800
committerGitHub <noreply@github.com>2019-01-11 05:39:12 -0800
commitb3eb23d671425775673f86bd02b9c89ef781f590 (patch)
tree5f06e4e289f16d9164d692590a3fe6541b5384cf /vendor/github.com/vishvananda/netlink/conntrack_linux.go
parent26f2b7debde313af4a5ae39727c66a3f8fd59be4 (diff)
parentbd40dcfc2bc7c9014ea1f33482fb63aacbcdfe87 (diff)
downloadpodman-b3eb23d671425775673f86bd02b9c89ef781f590.tar.gz
podman-b3eb23d671425775673f86bd02b9c89ef781f590.tar.bz2
podman-b3eb23d671425775673f86bd02b9c89ef781f590.zip
Merge pull request #2102 from vrothberg/vendor-update
vendor: update everything
Diffstat (limited to 'vendor/github.com/vishvananda/netlink/conntrack_linux.go')
-rw-r--r--vendor/github.com/vishvananda/netlink/conntrack_linux.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/vendor/github.com/vishvananda/netlink/conntrack_linux.go b/vendor/github.com/vishvananda/netlink/conntrack_linux.go
index ecf044565..a0fc74a37 100644
--- a/vendor/github.com/vishvananda/netlink/conntrack_linux.go
+++ b/vendor/github.com/vishvananda/netlink/conntrack_linux.go
@@ -6,9 +6,9 @@ import (
"errors"
"fmt"
"net"
- "syscall"
"github.com/vishvananda/netlink/nl"
+ "golang.org/x/sys/unix"
)
// ConntrackTableType Conntrack table for the netlink operation
@@ -85,8 +85,8 @@ func (h *Handle) ConntrackTableList(table ConntrackTableType, family InetFamily)
// conntrack -F [table] Flush table
// The flush operation applies to all the family types
func (h *Handle) ConntrackTableFlush(table ConntrackTableType) error {
- req := h.newConntrackRequest(table, syscall.AF_INET, nl.IPCTNL_MSG_CT_DELETE, syscall.NLM_F_ACK)
- _, err := req.Execute(syscall.NETLINK_NETFILTER, 0)
+ req := h.newConntrackRequest(table, unix.AF_INET, nl.IPCTNL_MSG_CT_DELETE, unix.NLM_F_ACK)
+ _, err := req.Execute(unix.NETLINK_NETFILTER, 0)
return err
}
@@ -102,10 +102,10 @@ func (h *Handle) ConntrackDeleteFilter(table ConntrackTableType, family InetFami
for _, dataRaw := range res {
flow := parseRawData(dataRaw)
if match := filter.MatchConntrackFlow(flow); match {
- req2 := h.newConntrackRequest(table, family, nl.IPCTNL_MSG_CT_DELETE, syscall.NLM_F_ACK)
+ req2 := h.newConntrackRequest(table, family, nl.IPCTNL_MSG_CT_DELETE, unix.NLM_F_ACK)
// skip the first 4 byte that are the netfilter header, the newConntrackRequest is adding it already
req2.AddRawData(dataRaw[4:])
- req2.Execute(syscall.NETLINK_NETFILTER, 0)
+ req2.Execute(unix.NETLINK_NETFILTER, 0)
matched++
}
}
@@ -127,8 +127,8 @@ func (h *Handle) newConntrackRequest(table ConntrackTableType, family InetFamily
}
func (h *Handle) dumpConntrackTable(table ConntrackTableType, family InetFamily) ([][]byte, error) {
- req := h.newConntrackRequest(table, family, nl.IPCTNL_MSG_CT_GET, syscall.NLM_F_DUMP)
- return req.Execute(syscall.NETLINK_NETFILTER, 0)
+ req := h.newConntrackRequest(table, family, nl.IPCTNL_MSG_CT_GET, unix.NLM_F_DUMP)
+ return req.Execute(unix.NETLINK_NETFILTER, 0)
}
// The full conntrack flow structure is very complicated and can be found in the file: