summaryrefslogtreecommitdiff
path: root/scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@vyos.io>2024-09-02 15:46:50 +0100
committerGitHub <noreply@github.com>2024-09-02 15:46:50 +0100
commit9833897b7c70d7a00caef420edea5dd2e359d522 (patch)
tree7282e5fe204b1aece7985d9397ee49341d715cb3 /scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch
parent013e4d5dc9472c6ea48a8f6e175d1cf9d4ca13d5 (diff)
parentcc7d0993b420c3245e628a818f887411d72530ff (diff)
downloadvyos-build-9833897b7c70d7a00caef420edea5dd2e359d522.tar.gz
vyos-build-9833897b7c70d7a00caef420edea5dd2e359d522.zip
Merge pull request #745 from sever-sever/T6674
T6674: Add build-scrips for packages without Jenkins
Diffstat (limited to 'scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch')
-rw-r--r--scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch17
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch b/scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch
new file mode 100644
index 00000000..b5751325
--- /dev/null
+++ b/scripts/package-build/wide-dhcpv6/patches/0024-bind-to-single-socket.patch
@@ -0,0 +1,17 @@
+diff --git a/dhcp6c.c b/dhcp6c.c
+index 1caaaa5..04ce9c5 100644
+--- a/dhcp6c.c
++++ b/dhcp6c.c
+@@ -217,6 +217,12 @@ main(argc, argv)
+ argv[0]);
+ exit(1);
+ }
++
++ if (setsockopt(sock, SOL_SOCKET, SO_BINDTODEVICE, argv[0], strlen(argv[0])) != 0) {
++ debug_printf(LOG_ERR, FNAME, "failed to bind %s", argv[0]);
++ exit(1);
++ }
++
+ argv++;
+ }
+