From 56253832a84530567d6b96b789d160b77622b1b9 Mon Sep 17 00:00:00 2001 From: phk Date: Wed, 22 Dec 2004 17:30:38 +0000 Subject: Include fcntl.h not vnode.h. Include uio.h instead of relying on vnode.h to do so. Check O_NONBLOCK not IO_NDELAY. --- sys/dev/snp/snp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sys/dev/snp') diff --git a/sys/dev/snp/snp.c b/sys/dev/snp/snp.c index a265dbc..c6d8c32 100644 --- a/sys/dev/snp/snp.c +++ b/sys/dev/snp/snp.c @@ -19,6 +19,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -28,7 +29,7 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include +#include static l_close_t snplclose; static l_write_t snplwrite; @@ -275,7 +276,7 @@ snpread(dev, uio, flag) do { if (snp->snp_len == 0) { - if (flag & IO_NDELAY) + if (flag & O_NONBLOCK) return (EWOULDBLOCK); snp->snp_flags |= SNOOP_RWAIT; error = tsleep(snp, (PZERO + 1) | PCATCH, -- cgit v1.1