taglinefilesource code
newsock92include/linux/net.hint  (*dup)    (struct socket *newsock, struct socket *oldsock);
newsock99include/linux/net.hint  (*accept)  (struct socket *sock, struct socket *newsock,
newsock730net/inet/af_inet.cstatic int inet_dup(struct socket *newsock, struct socket *oldsock)
newsock732net/inet/af_inet.creturn(inet_create(newsock,((struct sock *)(oldsock->data))->protocol));
newsock991net/inet/af_inet.cstatic int inet_accept(struct socket *sock, struct socket *newsock, int flags)
newsock1003net/inet/af_inet.cif (newsock->data)
newsock1005net/inet/af_inet.cstruct sock *sk=(struct sock *)newsock->data;
newsock1006net/inet/af_inet.cnewsock->data=NULL;
newsock1032net/inet/af_inet.cnewsock->data = (void *)sk2;
newsock1033net/inet/af_inet.csk2->sleep = newsock->wait;
newsock1034net/inet/af_inet.csk2->socket = newsock;
newsock1035net/inet/af_inet.cnewsock->conn = NULL;
newsock1049net/inet/af_inet.cnewsock->data = NULL;
newsock1061net/inet/af_inet.cnewsock->data = NULL;
newsock1064net/inet/af_inet.cnewsock->state = SS_CONNECTED;
newsock1409net/inet/ipx.cstatic int ipx_dup(struct socket *newsock,struct socket *oldsock)
newsock1411net/inet/ipx.creturn(ipx_create(newsock,SOCK_DGRAM));
newsock1518net/inet/ipx.cstatic int ipx_accept(struct socket *sock, struct socket *newsock, int flags)
newsock1520net/inet/ipx.cif(newsock->data)
newsock1521net/inet/ipx.ckfree_s(newsock->data,sizeof(ipx_socket));
newsock788net/socket.cstruct socket *sock, *newsock;
newsock806net/socket.cif (!(newsock = sock_alloc())) 
newsock812net/socket.cnewsock->type = sock->type;
newsock813net/socket.cnewsock->ops = sock->ops;
newsock814net/socket.cif ((i = sock->ops->dup(newsock, sock)) < 0) 
newsock816net/socket.csock_release(newsock);
newsock820net/socket.ci = newsock->ops->accept(sock, newsock, file->f_flags);
newsock823net/socket.csock_release(newsock);
newsock827net/socket.cif ((fd = get_fd(SOCK_INODE(newsock))) < 0) 
newsock829net/socket.csock_release(newsock);
newsock835net/socket.cnewsock->ops->getname(newsock, (struct sockaddr *)address, &len, 1);
newsock61net/unix/sock.cstatic int unix_proto_dup(struct socket *newsock, struct socket *oldsock);
newsock68net/unix/sock.cstatic int unix_proto_accept(struct socket *sock, struct socket *newsock, 
newsock341net/unix/sock.cstatic int unix_proto_dup(struct socket *newsock, struct socket *oldsock)
newsock344net/unix/sock.creturn(unix_proto_create(newsock, upd->protocol));
newsock535net/unix/sock.cstatic int unix_proto_accept(struct socket *sock, struct socket *newsock, int flags)
newsock563net/unix/sock.cnewsock->conn = clientsock;
newsock564net/unix/sock.cclientsock->conn = newsock;
newsock566net/unix/sock.cnewsock->state = SS_CONNECTED;
newsock568net/unix/sock.cUN_DATA(newsock)->peerupd       = UN_DATA(clientsock);
newsock569net/unix/sock.cUN_DATA(newsock)->sockaddr_un        = UN_DATA(sock)->sockaddr_un;
newsock570net/unix/sock.cUN_DATA(newsock)->sockaddr_len       = UN_DATA(sock)->sockaddr_len;