public bool KEvent(KernelEvent [] changeList, int nChanges, KernelEvent [] eventList, int nEvents, ref TimeSpec timeOut) { if (changeList != null && changeList.Length < nChanges) { throw new ArgumentException("nChanges is larger than the number of elements in changeList"); } if (eventList != null && eventList.Length < nEvents) { throw new ArgumentException("nChanges is larger than the number of elements in changeList"); } unsafe { fixed(KernelEvent *cp = &changeList[0]) fixed(KernelEvent * ep = &eventList [0]) return(kevent(handle, cp, nChanges, ep, nEvents, ref timeOut) != -1); } }
unsafe extern static int /* int */ kevent(int kq, KernelEvent *changeList, int /* int */ nChanges, KernelEvent *eventList, int /* int */ nEvents, ref TimeSpec timeout);