svn commit: r250072 - stable/9/sys/kern
Sergey Kandaurov
pluknet at FreeBSD.org
Mon Apr 29 21:11:22 UTC 2013
Author: pluknet
Date: Mon Apr 29 21:11:21 2013
New Revision: 250072
URL: http://svnweb.freebsd.org/changeset/base/250072
Log:
MFC r246826:
Add support of passing SCM_BINTIME ancillary data object for PF_LOCAL
sockets.
PR: kern/175883
Submitted by: Andrey Simonenko <simon at comsys.ntu-kpi.kiev.ua>
Modified:
stable/9/sys/kern/uipc_usrreq.c
Directory Properties:
stable/9/sys/ (props changed)
Modified: stable/9/sys/kern/uipc_usrreq.c
==============================================================================
--- stable/9/sys/kern/uipc_usrreq.c Mon Apr 29 21:11:05 2013 (r250071)
+++ stable/9/sys/kern/uipc_usrreq.c Mon Apr 29 21:11:21 2013 (r250072)
@@ -1815,6 +1815,7 @@ unp_internalize(struct mbuf **controlp,
struct mbuf *control = *controlp;
struct proc *p = td->td_proc;
struct filedesc *fdescp = p->p_fd;
+ struct bintime *bt;
struct cmsghdr *cm = mtod(control, struct cmsghdr *);
struct cmsgcred *cmcred;
struct file **rp;
@@ -1923,6 +1924,18 @@ unp_internalize(struct mbuf **controlp,
microtime(tv);
break;
+ case SCM_BINTIME:
+ *controlp = sbcreatecontrol(NULL, sizeof(*bt),
+ SCM_BINTIME, SOL_SOCKET);
+ if (*controlp == NULL) {
+ error = ENOBUFS;
+ goto out;
+ }
+ bt = (struct bintime *)
+ CMSG_DATA(mtod(*controlp, struct cmsghdr *));
+ bintime(bt);
+ break;
+
default:
error = EINVAL;
goto out;
More information about the svn-src-stable-9
mailing list