FreeBSD/sys/fs/devfs/devfs_dir.c
/* Returns 1 if the path is in the directory list. */
Returns 1 if the path is in the directory list.
Returns 1 if the path is in the directory list .
int
devfs_dir_find(const char *path)
{
	struct dirlistent *dle;
	mtx_lock(&dirlist_mtx);
	LIST_FOREACH(dle, &devfs_dirlist, link) {
		if (devfs_pathpath(dle->dir, path) != 0) {
			mtx_unlock(&dirlist_mtx);
			return (1);
		}
	}
	mtx_unlock(&dirlist_mtx);
	return (0);
}
int devfs_dir_find ( const char * path ) { struct dirlistent * dle ; mtx_lock ( & dirlist_mtx ) ; LIST_FOREACH ( dle , & devfs_dirlist , link ) { if ( devfs_pathpath ( dle -> dir , path ) != 0 ) { mtx_unlock ( & dirlist_mtx ) ; return ( 1 ) ; } } mtx_unlock ( & dirlist_mtx ) ; return ( 0 ) ; }
Returns 1 if the path is in the directory list.
Returns 1 if the path is in the directory list .