summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastiaan van Stijn <github@gone.nl>2023-04-08 22:34:51 +0200
committerSebastiaan van Stijn <github@gone.nl>2023-04-13 15:02:16 +0200
commit9277e644442e5e0f720d7539d38d4a4402d1ba55 (patch)
tree1ad83bf1b62d1676315325b0160cd4f52cf9add0
parentcdb6200887b4e6ce668c1a1e2436f321ea6c7936 (diff)
downloaddocker-9277e644442e5e0f720d7539d38d4a4402d1ba55.tar.gz
vendor: github.com/ishidawataru/sctp v0.0.0-20230406120618-7ff4192f6ff2
- Prevent from descriptor leak - Fixes optlen in getsockopt() for s390x full diff: https://github.com/ishidawataru/sctp/compare/9a39160e9062...7ff4192f6ff2b4b181ec7dce269bdf4076ff90a0 Signed-off-by: Sebastiaan van Stijn <github@gone.nl> (cherry picked from commit 893d28469f873a8b44d428b67046bcea2b600fd9) Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
-rw-r--r--vendor.mod2
-rw-r--r--vendor.sum4
-rw-r--r--vendor/github.com/ishidawataru/sctp/sctp_linux.go6
-rw-r--r--vendor/modules.txt2
4 files changed, 9 insertions, 5 deletions
diff --git a/vendor.mod b/vendor.mod
index 55852937b3..f2c586f604 100644
--- a/vendor.mod
+++ b/vendor.mod
@@ -46,7 +46,7 @@ require (
github.com/hashicorp/memberlist v0.4.0
github.com/hashicorp/serf v0.8.5
github.com/imdario/mergo v0.3.12
- github.com/ishidawataru/sctp v0.0.0-20210707070123-9a39160e9062
+ github.com/ishidawataru/sctp v0.0.0-20230406120618-7ff4192f6ff2
github.com/klauspost/compress v1.15.12
github.com/miekg/dns v1.1.43
github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible
diff --git a/vendor.sum b/vendor.sum
index 65a702ffd6..4ad34e14ca 100644
--- a/vendor.sum
+++ b/vendor.sum
@@ -644,8 +644,8 @@ github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc=
github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
-github.com/ishidawataru/sctp v0.0.0-20210707070123-9a39160e9062 h1:G1+wBT0dwjIrBdLy0MIG0i+E4CQxEnedHXdauJEIH6g=
-github.com/ishidawataru/sctp v0.0.0-20210707070123-9a39160e9062/go.mod h1:co9pwDoBCm1kGxawmb4sPq0cSIOOWNPT4KnHotMP1Zg=
+github.com/ishidawataru/sctp v0.0.0-20230406120618-7ff4192f6ff2 h1:i2fYnDurfLlJH8AyyMOnkLHnHeP8Ff/DDpuZA/D3bPo=
+github.com/ishidawataru/sctp v0.0.0-20230406120618-7ff4192f6ff2/go.mod h1:co9pwDoBCm1kGxawmb4sPq0cSIOOWNPT4KnHotMP1Zg=
github.com/j-keck/arping v0.0.0-20160618110441-2cf9dc699c56/go.mod h1:ymszkNOg6tORTn+6F6j+Jc8TOr5osrynvN6ivFWZ2GA=
github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
github.com/jmespath/go-jmespath v0.0.0-20160803190731-bd40a432e4c7/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
diff --git a/vendor/github.com/ishidawataru/sctp/sctp_linux.go b/vendor/github.com/ishidawataru/sctp/sctp_linux.go
index d96d09e5ca..e11d012cff 100644
--- a/vendor/github.com/ishidawataru/sctp/sctp_linux.go
+++ b/vendor/github.com/ishidawataru/sctp/sctp_linux.go
@@ -22,6 +22,7 @@ import (
"sync/atomic"
"syscall"
"unsafe"
+ "runtime"
)
func setsockopt(fd int, optname, optval, optlen uintptr) (uintptr, uintptr, error) {
@@ -40,6 +41,9 @@ func setsockopt(fd int, optname, optval, optlen uintptr) (uintptr, uintptr, erro
}
func getsockopt(fd int, optname, optval, optlen uintptr) (uintptr, uintptr, error) {
+ if runtime.GOARCH == "s390x" {
+ optlen = uintptr(unsafe.Pointer(&optlen))
+ }
// FIXME: syscall.SYS_GETSOCKOPT is undefined on 386
r0, r1, errno := syscall.Syscall6(syscall.SYS_GETSOCKOPT,
uintptr(fd),
@@ -292,7 +296,7 @@ func dialSCTPExtConfig(network string, laddr, raddr *SCTPAddr, options InitMsg,
laddr.IPAddrs = append(laddr.IPAddrs, net.IPAddr{IP: net.IPv6zero})
}
}
- err := SCTPBind(sock, laddr, SCTP_BINDX_ADD_ADDR)
+ err = SCTPBind(sock, laddr, SCTP_BINDX_ADD_ADDR)
if err != nil {
return nil, err
}
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 641f9c6fdc..fda547e882 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -459,7 +459,7 @@ github.com/imdario/mergo
# github.com/inconshreveable/mousetrap v1.0.1
## explicit; go 1.18
github.com/inconshreveable/mousetrap
-# github.com/ishidawataru/sctp v0.0.0-20210707070123-9a39160e9062
+# github.com/ishidawataru/sctp v0.0.0-20230406120618-7ff4192f6ff2
## explicit; go 1.12
github.com/ishidawataru/sctp
# github.com/jmespath/go-jmespath v0.4.0