Lines Matching refs:msg
134 static void printpacket(struct msghdr *msg, int res, in printpacket() argument
139 struct sockaddr_in *from_addr = (struct sockaddr_in *)msg->msg_name; in printpacket()
152 msg->msg_controllen); in printpacket()
153 for (cmsg = CMSG_FIRSTHDR(msg); in printpacket()
155 cmsg = CMSG_NXTHDR(msg, cmsg)) { in printpacket()
263 struct msghdr msg; in recvpacket() local
272 memset(&msg, 0, sizeof(msg)); in recvpacket()
273 msg.msg_iov = &entry; in recvpacket()
274 msg.msg_iovlen = 1; in recvpacket()
277 msg.msg_name = (caddr_t)&from_addr; in recvpacket()
278 msg.msg_namelen = sizeof(from_addr); in recvpacket()
279 msg.msg_control = &control; in recvpacket()
280 msg.msg_controllen = sizeof(control); in recvpacket()
282 res = recvmsg(sock, &msg, recvmsg_flags|MSG_DONTWAIT); in recvpacket()
289 printpacket(&msg, res, data, in recvpacket()