/*
- * Copyright (c) 2005 Apple Computer, Inc. All rights reserved.
+ * Copyright (c) 2005-2006 Apple Computer, Inc. All rights reserved.
*
* @APPLE_OSREFERENCE_LICENSE_HEADER_START@
*
sbi->sbi_mbmax = sb->sb_mbmax;
sbi->sbi_lowat = sb->sb_lowat;
sbi->sbi_flags = sb->sb_flags;
- sbi->sbi_timeo = (u_long)(sb->sb_timeo.tv_sec * hz) + sb->sb_timeo.tv_usec / tick;
+ sbi->sbi_timeo = (u_int32_t)(sb->sb_timeo.tv_sec * hz) + sb->sb_timeo.tv_usec / tick;
if (sbi->sbi_timeo == 0 && sb->sb_timeo.tv_usec != 0)
sbi->sbi_timeo = 1;
}
insi->insi_v4.in4_tos = inp->inp_depend4.inp4_ip_tos;
insi->insi_v6.in6_hlim = inp->inp_depend6.inp6_hlim;
insi->insi_v6.in6_cksum = inp->inp_depend6.inp6_cksum;
- insi->insi_v6.in6_ifindex = inp->inp6_ifindex;
+ insi->insi_v6.in6_ifindex = inp->inp_depend6.inp6_ifindex;
insi->insi_v6.in6_hops = inp->inp_depend6.inp6_hops;
if (type == SOCK_STREAM && (protocol == 0 || protocol == IPPROTO_TCP) && inp->inp_ppcb != 0) {
ndrvsi->ndrvsi_if_family = ifp->if_family;
ndrvsi->ndrvsi_if_unit = ifp->if_unit;
- strncpy(ndrvsi->ndrvsi_if_name, ifp->if_name, IFNAMSIZ);
+ strlcpy(ndrvsi->ndrvsi_if_name, ifp->if_name, IFNAMSIZ);
}
break;
kcsi->kcsi_recvbufsize = kctl->recvbufsize;
kcsi->kcsi_sendbufsize = kctl->sendbufsize;
kcsi->kcsi_unit = kcb->unit;
- strncpy(kcsi->kcsi_name, kctl->name, MAX_KCTL_NAME);
+ strlcpy(kcsi->kcsi_name, kctl->name, MAX_KCTL_NAME);
}
break;