version 1.45, 1999/06/17 23:17:45 |
version 1.46, 2000/03/30 09:27:14 |
Line 131 unp_output(m, control, unp, p) |
|
Line 131 unp_output(m, control, unp, p) |
|
|
|
void |
void |
unp_setsockaddr(unp, nam) |
unp_setsockaddr(unp, nam) |
register struct unpcb *unp; |
struct unpcb *unp; |
struct mbuf *nam; |
struct mbuf *nam; |
{ |
{ |
struct sockaddr_un *sun; |
struct sockaddr_un *sun; |
Line 148 unp_setsockaddr(unp, nam) |
|
Line 148 unp_setsockaddr(unp, nam) |
|
|
|
void |
void |
unp_setpeeraddr(unp, nam) |
unp_setpeeraddr(unp, nam) |
register struct unpcb *unp; |
struct unpcb *unp; |
struct mbuf *nam; |
struct mbuf *nam; |
{ |
{ |
struct sockaddr_un *sun; |
struct sockaddr_un *sun; |
Line 172 uipc_usrreq(so, req, m, nam, control, p) |
|
Line 172 uipc_usrreq(so, req, m, nam, control, p) |
|
struct proc *p; |
struct proc *p; |
{ |
{ |
struct unpcb *unp = sotounpcb(so); |
struct unpcb *unp = sotounpcb(so); |
register struct socket *so2; |
struct socket *so2; |
register int error = 0; |
int error = 0; |
|
|
if (req == PRU_CONTROL) |
if (req == PRU_CONTROL) |
return (EOPNOTSUPP); |
return (EOPNOTSUPP); |
|
|
unp_attach(so) |
unp_attach(so) |
struct socket *so; |
struct socket *so; |
{ |
{ |
register struct unpcb *unp; |
struct unpcb *unp; |
struct timeval tv; |
struct timeval tv; |
int error; |
int error; |
|
|
|
|
|
|
void |
void |
unp_detach(unp) |
unp_detach(unp) |
register struct unpcb *unp; |
struct unpcb *unp; |
{ |
{ |
|
|
if (unp->unp_vnode) { |
if (unp->unp_vnode) { |
Line 556 unp_bind(unp, nam, p) |
|
Line 556 unp_bind(unp, nam, p) |
|
struct proc *p; |
struct proc *p; |
{ |
{ |
struct sockaddr_un *sun; |
struct sockaddr_un *sun; |
register struct vnode *vp; |
struct vnode *vp; |
struct vattr vattr; |
struct vattr vattr; |
size_t addrlen; |
size_t addrlen; |
int error; |
int error; |
Line 618 unp_connect(so, nam, p) |
|
Line 618 unp_connect(so, nam, p) |
|
struct mbuf *nam; |
struct mbuf *nam; |
struct proc *p; |
struct proc *p; |
{ |
{ |
register struct sockaddr_un *sun; |
struct sockaddr_un *sun; |
register struct vnode *vp; |
struct vnode *vp; |
register struct socket *so2, *so3; |
struct socket *so2, *so3; |
struct unpcb *unp2, *unp3; |
struct unpcb *unp2, *unp3; |
size_t addrlen; |
size_t addrlen; |
int error; |
int error; |
Line 685 unp_connect(so, nam, p) |
|
Line 685 unp_connect(so, nam, p) |
|
|
|
int |
int |
unp_connect2(so, so2) |
unp_connect2(so, so2) |
register struct socket *so; |
struct socket *so; |
register struct socket *so2; |
struct socket *so2; |
{ |
{ |
register struct unpcb *unp = sotounpcb(so); |
struct unpcb *unp = sotounpcb(so); |
register struct unpcb *unp2; |
struct unpcb *unp2; |
|
|
if (so2->so_type != so->so_type) |
if (so2->so_type != so->so_type) |
return (EPROTOTYPE); |
return (EPROTOTYPE); |
|
|
unp_disconnect(unp) |
unp_disconnect(unp) |
struct unpcb *unp; |
struct unpcb *unp; |
{ |
{ |
register struct unpcb *unp2 = unp->unp_conn; |
struct unpcb *unp2 = unp->unp_conn; |
|
|
if (unp2 == 0) |
if (unp2 == 0) |
return; |
return; |
Line 802 unp_externalize(rights) |
|
Line 802 unp_externalize(rights) |
|
struct mbuf *rights; |
struct mbuf *rights; |
{ |
{ |
struct proc *p = curproc; /* XXX */ |
struct proc *p = curproc; /* XXX */ |
register struct cmsghdr *cm = mtod(rights, struct cmsghdr *); |
struct cmsghdr *cm = mtod(rights, struct cmsghdr *); |
register int i, *fdp = (int *)(cm + 1); |
int i, *fdp = (int *)(cm + 1); |
register struct file **rp; |
struct file **rp; |
register struct file *fp; |
struct file *fp; |
int nfds = (cm->cmsg_len - ALIGN(sizeof(*cm))) / sizeof(struct file *); |
int nfds = (cm->cmsg_len - ALIGN(sizeof(*cm))) / sizeof(struct file *); |
int f, error = 0; |
int f, error = 0; |
|
|
Line 878 unp_internalize(control, p) |
|
Line 878 unp_internalize(control, p) |
|
struct proc *p; |
struct proc *p; |
{ |
{ |
struct filedesc *fdescp = p->p_fd; |
struct filedesc *fdescp = p->p_fd; |
register struct cmsghdr *cm = mtod(control, struct cmsghdr *); |
struct cmsghdr *cm = mtod(control, struct cmsghdr *); |
register struct file **rp; |
struct file **rp; |
register struct file *fp; |
struct file *fp; |
register int i, fd, *fdp; |
int i, fd, *fdp; |
int nfds; |
int nfds; |
u_int neededspace; |
u_int neededspace; |
|
|
Line 1041 extern struct domain unixdomain; |
|
Line 1041 extern struct domain unixdomain; |
|
void |
void |
unp_gc() |
unp_gc() |
{ |
{ |
register struct file *fp, *nextfp; |
struct file *fp, *nextfp; |
register struct socket *so, *so1; |
struct socket *so, *so1; |
struct file **extra_ref, **fpp; |
struct file **extra_ref, **fpp; |
int nunref, i; |
int nunref, i; |
|
|
|
|
|
|
void |
void |
unp_scan(m0, op, discard) |
unp_scan(m0, op, discard) |
register struct mbuf *m0; |
struct mbuf *m0; |
void (*op) __P((struct file *)); |
void (*op) __P((struct file *)); |
int discard; |
int discard; |
{ |
{ |
register struct mbuf *m; |
struct mbuf *m; |
register struct file **rp; |
struct file **rp; |
register struct cmsghdr *cm; |
struct cmsghdr *cm; |
register int i; |
int i; |
int qfds; |
int qfds; |
|
|
while (m0) { |
while (m0) { |