(struct sonode *, struct nmsghdr *, struct uio *) = NULL;
int (*sockfs_sosetsockopt)
(struct sonode *, int, int, void *, int) = NULL;
+#ifndef AFS_SUN510_ENV
int (*sockfs_sounbind)
(struct sonode *, int);
void (*sockfs_sockfree)
(struct sonode *);
+#endif
static afs_uint32 myNetAddrs[ADDRSPERSITE];
static int myNetMTUs[ADDRSPERSITE];
ill_t *ill;
ipif_t *ipif;
int rxmtu, maxmtu;
+#ifdef AFS_SUN510_ENV
+ ill_walk_context_t ctx;
+#endif
int mtus[ADDRSPERSITE];
afs_uint32 addrs[ADDRSPERSITE];
memset(mtus, 0, sizeof(mtus));
memset(addrs, 0, sizeof(addrs));
+#ifdef AFS_SUN510_ENV
+ for (ill = ILL_START_WALK_ALL(&ctx) ; ill ; ill = ill_next(&ctx, ill)) {
+#else
for (ill = ill_g_head; ill; ill = ill->ill_next) {
+#endif
#ifdef AFS_SUN58_ENV
/* Make sure this is an IPv4 ILL */
if (ill->ill_isv6)
afs_uint32 myAddr, netMask;
int match_value = 0;
int mtu = -1;
+#ifdef AFS_SUN510_ENV
+ ill_walk_context_t ctx;
+#endif
if (numMyNetAddrs == 0)
rxi_GetIFInfo();
else
netMask = 0;
+#ifdef AFS_SUN510_ENV
+ for (ill = ILL_START_WALK_ALL(&ctx) ; ill ; ill = ill_next(&ctx, ill)) {
+#else
for (ill = ill_g_head; ill; ill = ill->ill_next) {
+#endif
#ifdef AFS_SUN58_ENV
/* Make sure this is an IPv4 ILL */
if (ill->ill_isv6)
return NULL;
}
}
+#ifndef AFS_SUN510_ENV
if (sockfs_sounbind == NULL) {
sockfs_sounbind = (int (*)())modlookup("sockfs", "sounbind");
if (sockfs_sounbind == NULL)
if (sockfs_sockfree == NULL)
return NULL;
}
+#endif
accessvp = sockfs_solookup(AF_INET, SOCK_DGRAM, 0, "/dev/udp", &error);
if (accessvp == NULL) {
struct sockaddr_in taddr;
struct iovec dvec;
char c;
+ vnode_t *vp;
AFS_STATCNT(osi_FreeSocket);
afs_osi_Sleep(&rxk_ListenerPid);
}
- sockfs_sounbind(so, 0);
- sockfs_sockfree(so);
+ /* Was sockfs_sounbind(so, 0); sockfs_sockfree(so); That's wrong */
+ vp = SOTOV(so);
+ VOP_CLOSE(vp, FREAD|FWRITE, 1, (offset_t)0, CRED());
+ VN_RELE(vp);
+
return 0;
}