aboutsummaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2022-08-30 23:21:19 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2022-08-30 23:24:37 +0000
commit1df08e905a0b093bd05ac93761bacabc92171629 (patch)
tree8d3ce80fba49efe53849ae3398cb98f9edffabd8 /sbin
parent2a63683b5d5c480d0f652f0ea9cf6b9621d55920 (diff)
downloadsrc-1df08e905a0b093bd05ac93761bacabc92171629.tar.gz
src-1df08e905a0b093bd05ac93761bacabc92171629.zip
Diffstat (limited to 'sbin')
-rw-r--r--sbin/natd/natd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sbin/natd/natd.c b/sbin/natd/natd.c
index 402c430dfdfd..599a5247ac85 100644
--- a/sbin/natd/natd.c
+++ b/sbin/natd/natd.c
@@ -226,7 +226,7 @@ int main (int argc, char** argv)
*/
if (mip->inOutPort) {
- mip->divertInOut = socket (PF_INET, SOCK_RAW, IPPROTO_DIVERT);
+ mip->divertInOut = socket(PF_DIVERT, SOCK_RAW, 0);
if (mip->divertInOut == -1)
Quit ("Unable to create divert socket.");
if (mip->divertInOut > fdMax)
@@ -249,14 +249,14 @@ int main (int argc, char** argv)
}
else {
- mip->divertIn = socket (PF_INET, SOCK_RAW, IPPROTO_DIVERT);
+ mip->divertIn = socket(PF_DIVERT, SOCK_RAW, 0);
if (mip->divertIn == -1)
Quit ("Unable to create incoming divert socket.");
if (mip->divertIn > fdMax)
fdMax = mip->divertIn;
- mip->divertOut = socket (PF_INET, SOCK_RAW, IPPROTO_DIVERT);
+ mip->divertOut = socket(PF_DIVERT, SOCK_RAW, 0);
if (mip->divertOut == -1)
Quit ("Unable to create outgoing divert socket.");
if (mip->divertOut > fdMax)
@@ -317,7 +317,7 @@ int main (int argc, char** argv)
}
if (globalPort) {
- divertGlobal = socket (PF_INET, SOCK_RAW, IPPROTO_DIVERT);
+ divertGlobal = socket(PF_DIVERT, SOCK_RAW, 0);
if (divertGlobal == -1)
Quit ("Unable to create divert socket.");
if (divertGlobal > fdMax)