Deleted Added
full compact
route6d.c (312022) route6d.c (314427)
1/* $FreeBSD: stable/11/usr.sbin/route6d/route6d.c 312022 2017-01-13 08:27:07Z ngie $ */
1/* $FreeBSD: stable/11/usr.sbin/route6d/route6d.c 314427 2017-02-28 22:49:41Z asomers $ */
2/* $KAME: route6d.c,v 1.104 2003/10/31 00:30:20 itojun Exp $ */
3
4/*
5 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 1047 unchanged lines hidden (view full) ---

1057 idx = 0;
1058
1059 m.msg_name = (caddr_t)sin6;
1060 m.msg_namelen = sizeof(*sin6);
1061 iov[0].iov_base = (caddr_t)ripbuf;
1062 iov[0].iov_len = len;
1063 m.msg_iov = iov;
1064 m.msg_iovlen = 1;
2/* $KAME: route6d.c,v 1.104 2003/10/31 00:30:20 itojun Exp $ */
3
4/*
5 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 1047 unchanged lines hidden (view full) ---

1057 idx = 0;
1058
1059 m.msg_name = (caddr_t)sin6;
1060 m.msg_namelen = sizeof(*sin6);
1061 iov[0].iov_base = (caddr_t)ripbuf;
1062 iov[0].iov_len = len;
1063 m.msg_iov = iov;
1064 m.msg_iovlen = 1;
1065 m.msg_flags = 0;
1065 if (!idx) {
1066 m.msg_control = NULL;
1067 m.msg_controllen = 0;
1068 } else {
1069 memset(cmsgbuf, 0, sizeof(cmsgbuf));
1070 cm = (struct cmsghdr *)cmsgbuf;
1071 m.msg_control = (caddr_t)cm;
1072 m.msg_controllen = CMSG_SPACE(sizeof(struct in6_pktinfo));

--- 48 unchanged lines hidden (view full) ---

1121 m.msg_namelen = sizeof(fsock);
1122 iov[0].iov_base = (caddr_t)buf;
1123 iov[0].iov_len = sizeof(buf);
1124 m.msg_iov = iov;
1125 m.msg_iovlen = 1;
1126 cm = (struct cmsghdr *)cmsgbuf;
1127 m.msg_control = (caddr_t)cm;
1128 m.msg_controllen = sizeof(cmsgbuf);
1066 if (!idx) {
1067 m.msg_control = NULL;
1068 m.msg_controllen = 0;
1069 } else {
1070 memset(cmsgbuf, 0, sizeof(cmsgbuf));
1071 cm = (struct cmsghdr *)cmsgbuf;
1072 m.msg_control = (caddr_t)cm;
1073 m.msg_controllen = CMSG_SPACE(sizeof(struct in6_pktinfo));

--- 48 unchanged lines hidden (view full) ---

1122 m.msg_namelen = sizeof(fsock);
1123 iov[0].iov_base = (caddr_t)buf;
1124 iov[0].iov_len = sizeof(buf);
1125 m.msg_iov = iov;
1126 m.msg_iovlen = 1;
1127 cm = (struct cmsghdr *)cmsgbuf;
1128 m.msg_control = (caddr_t)cm;
1129 m.msg_controllen = sizeof(cmsgbuf);
1130 m.msg_flags = 0;
1129 if ((len = recvmsg(ripsock, &m, 0)) < 0) {
1130 fatal("recvmsg");
1131 /*NOTREACHED*/
1132 }
1133 idx = 0;
1134 for (cm = (struct cmsghdr *)CMSG_FIRSTHDR(&m);
1135 cm;
1136 cm = (struct cmsghdr *)CMSG_NXTHDR(&m, cm)) {

--- 2485 unchanged lines hidden ---
1131 if ((len = recvmsg(ripsock, &m, 0)) < 0) {
1132 fatal("recvmsg");
1133 /*NOTREACHED*/
1134 }
1135 idx = 0;
1136 for (cm = (struct cmsghdr *)CMSG_FIRSTHDR(&m);
1137 cm;
1138 cm = (struct cmsghdr *)CMSG_NXTHDR(&m, cm)) {

--- 2485 unchanged lines hidden ---