MCPcopy Create free account
hub / github.com/F-Stack/f-stack / fdeget_locked

Function fdeget_locked

freebsd/sys/filedesc.h:302–317  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

300}
301
302static __inline struct filedescent *
303fdeget_locked(struct filedesc *fdp, int fd)
304{
305 struct filedescent *fde;
306
307 FILEDESC_LOCK_ASSERT(fdp);
308
309 if (__predict_false((u_int)fd >= fdp->fd_nfiles))
310 return (NULL);
311
312 fde = &fdp->fd_ofiles[fd];
313 if (__predict_false(fde->fde_file == NULL))
314 return (NULL);
315
316 return (fde);
317}
318
319#ifdef CAPABILITIES
320static __inline bool

Callers 8

kern_cap_rights_limitFunction · 0.85
cap_ioctl_checkFunction · 0.85
kern_cap_ioctls_limitFunction · 0.85
sys_cap_ioctls_getFunction · 0.85
sys_cap_fcntls_limitFunction · 0.85
sys_cap_fcntls_getFunction · 0.85
kern_fcntlFunction · 0.85
fget_cap_lockedFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected