diff options
author | brian <brian@FreeBSD.org> | 2002-01-16 13:15:47 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 2002-01-16 13:15:47 +0000 |
commit | 414245183e4efd4326ea425a932f73c5cc9dd073 (patch) | |
tree | ad1919513333486a2fc89f76e42e8fbb384f259a | |
parent | d056f34b3633cfdaba110d2f791a09d9a564773d (diff) | |
download | FreeBSD-src-414245183e4efd4326ea425a932f73c5cc9dd073.zip FreeBSD-src-414245183e4efd4326ea425a932f73c5cc9dd073.tar.gz |
socket's first argument is an address family, not a protocol family.
-rw-r--r-- | usr.sbin/ppp/arp.c | 2 | ||||
-rw-r--r-- | usr.sbin/ppp/atm.c | 2 | ||||
-rw-r--r-- | usr.sbin/ppp/mp.c | 2 | ||||
-rw-r--r-- | usr.sbin/ppp/route.c | 4 | ||||
-rw-r--r-- | usr.sbin/ppp/server.c | 6 | ||||
-rw-r--r-- | usr.sbin/ppp/tcp.c | 2 | ||||
-rw-r--r-- | usr.sbin/ppp/udp.c | 2 |
7 files changed, 10 insertions, 10 deletions
diff --git a/usr.sbin/ppp/arp.c b/usr.sbin/ppp/arp.c index 47b7869..edcc37c 100644 --- a/usr.sbin/ppp/arp.c +++ b/usr.sbin/ppp/arp.c @@ -112,7 +112,7 @@ arp_ProxySub(struct bundle *bundle, struct in_addr addr, int add, int s) inet_ntoa(addr)); return 0; } - routes = ID0socket(PF_ROUTE, SOCK_RAW, AF_INET); + routes = ID0socket(AF_ROUTE, SOCK_RAW, AF_INET); if (routes < 0) { log_Printf(LogERROR, "arp_SetProxy: opening routing socket: %s\n", strerror(errno)); diff --git a/usr.sbin/ppp/atm.c b/usr.sbin/ppp/atm.c index 6d6aba9..4a6356a 100644 --- a/usr.sbin/ppp/atm.c +++ b/usr.sbin/ppp/atm.c @@ -184,7 +184,7 @@ atm_CreateDevice(struct physical *p, const char *iface, unsigned vpi, log_Printf(LogPHASE, "%s: Connecting to %s:%u.%u\n", p->link.name, iface, vpi, vci); - p->fd = socket(PF_NATM, SOCK_DGRAM, PROTO_NATMAAL5); + p->fd = socket(AF_NATM, SOCK_DGRAM, PROTO_NATMAAL5); if (p->fd >= 0) { log_Printf(LogDEBUG, "%s: Opened atm socket %s\n", p->link.name, p->name.full); diff --git a/usr.sbin/ppp/mp.c b/usr.sbin/ppp/mp.c index f288c8d..e6254a6 100644 --- a/usr.sbin/ppp/mp.c +++ b/usr.sbin/ppp/mp.c @@ -1137,7 +1137,7 @@ mpserver_Open(struct mpserver *s, struct peerid *peer) s->socket.sun_family = AF_LOCAL; s->socket.sun_len = sizeof s->socket; - s->fd = ID0socket(PF_LOCAL, SOCK_DGRAM, 0); + s->fd = ID0socket(AF_LOCAL, SOCK_DGRAM, 0); if (s->fd < 0) { log_Printf(LogERROR, "mpserver: socket(): %s\n", strerror(errno)); return MPSERVER_FAILED; diff --git a/usr.sbin/ppp/route.c b/usr.sbin/ppp/route.c index 5f0f662..a1ecd33 100644 --- a/usr.sbin/ppp/route.c +++ b/usr.sbin/ppp/route.c @@ -723,7 +723,7 @@ rt_Set(struct bundle *bundle, int cmd, const struct ncprange *dst, cmdstr = (cmd == RTM_ADD ? "Add!" : "Delete!"); else cmdstr = (cmd == RTM_ADD ? "Add" : "Delete"); - s = ID0socket(PF_ROUTE, SOCK_RAW, 0); + s = ID0socket(AF_ROUTE, SOCK_RAW, 0); if (s < 0) { log_Printf(LogERROR, "rt_Set: socket(): %s\n", strerror(errno)); return result; @@ -835,7 +835,7 @@ rt_Update(struct bundle *bundle, const struct sockaddr *dst, char *p; int s, wb; - s = ID0socket(PF_ROUTE, SOCK_RAW, 0); + s = ID0socket(AF_ROUTE, SOCK_RAW, 0); if (s < 0) { log_Printf(LogERROR, "rt_Update: socket(): %s\n", strerror(errno)); return; diff --git a/usr.sbin/ppp/server.c b/usr.sbin/ppp/server.c index c696771..3fa12ae 100644 --- a/usr.sbin/ppp/server.c +++ b/usr.sbin/ppp/server.c @@ -259,7 +259,7 @@ server_LocalOpen(struct bundle *bundle, const char *name, mode_t mask) ifsun.sun_family = AF_LOCAL; strcpy(ifsun.sun_path, name); - s = socket(PF_LOCAL, SOCK_STREAM, 0); + s = socket(AF_LOCAL, SOCK_STREAM, 0); if (s < 0) { log_Printf(LogERROR, "Local: socket: %s\n", strerror(errno)); goto failed; @@ -328,7 +328,7 @@ server_TcpOpen(struct bundle *bundle, u_short port) sin6->sin6_port = htons(port); sin6->sin6_len = (u_int8_t)sizeof ss; sz = sizeof *sin6; - s = socket(PF_INET6, SOCK_STREAM, 0); + s = socket(AF_INET6, SOCK_STREAM, 0); } else #endif { @@ -337,7 +337,7 @@ server_TcpOpen(struct bundle *bundle, u_short port) sin->sin_len = (u_int8_t)sizeof ss; sin->sin_addr.s_addr = INADDR_ANY; sz = sizeof *sin; - s = socket(PF_INET, SOCK_STREAM, 0); + s = socket(AF_INET, SOCK_STREAM, 0); } if (s < 0) { diff --git a/usr.sbin/ppp/tcp.c b/usr.sbin/ppp/tcp.c index 567072a..5a66251 100644 --- a/usr.sbin/ppp/tcp.c +++ b/usr.sbin/ppp/tcp.c @@ -84,7 +84,7 @@ tcp_OpenConnection(const char *name, char *host, char *port) } log_Printf(LogPHASE, "%s: Connecting to %s:%s/tcp\n", name, host, port); - sock = socket(PF_INET, SOCK_STREAM, 0); + sock = socket(AF_INET, SOCK_STREAM, 0); if (sock < 0) return -2; diff --git a/usr.sbin/ppp/udp.c b/usr.sbin/ppp/udp.c index 8307a4a..fa76333 100644 --- a/usr.sbin/ppp/udp.c +++ b/usr.sbin/ppp/udp.c @@ -229,7 +229,7 @@ udp_CreateDevice(struct physical *p, char *host, char *port) log_Printf(LogPHASE, "%s: Connecting to %s:%s/udp\n", p->link.name, host, port); - p->fd = socket(PF_INET, SOCK_DGRAM, 0); + p->fd = socket(AF_INET, SOCK_DGRAM, 0); if (p->fd >= 0) { log_Printf(LogDEBUG, "%s: Opened udp socket %s\n", p->link.name, p->name.full); |