Declare "cnt" (a number of bytes to read or write) as an "ssize_t", not

as a "long" in dofileread() and dofilewrite().

Discussed with:	jhb
This commit is contained in:
cperciva 2005-02-10 20:19:17 +00:00
parent 7294dae01f
commit e1f5bc1828

View File

@ -162,7 +162,8 @@ dofileread(td, fp, fd, buf, nbyte, offset, flags)
{
struct uio auio;
struct iovec aiov;
long cnt, error = 0;
ssize_t cnt;
long error = 0;
#ifdef KTRACE
struct uio *ktruio = NULL;
#endif
@ -350,7 +351,8 @@ dofilewrite(td, fp, fd, buf, nbyte, offset, flags)
{
struct uio auio;
struct iovec aiov;
long cnt, error = 0;
ssize_t cnt;
long error = 0;
#ifdef KTRACE
struct uio *ktruio = NULL;
#endif