MFC r209262:

r209186:

BIO_DELETE contains range we want to delete and doesn't provide any
useful data, so there is no need to copy it to userland.

r209187:

'unit' can be negative, so use signed type for it.

Found by:	Coverity Prevent
CID:		3731

Approved by:	re (kensmith)
This commit is contained in:
Pawel Jakub Dawidek 2010-06-23 23:03:25 +00:00
parent b6bfb5a01f
commit 4e3eb21c22
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/releng/8.1/; revision=209487

View File

@ -210,7 +210,7 @@ g_gate_start(struct bio *bp)
}
static struct g_gate_softc *
g_gate_hold(u_int unit, const char *name)
g_gate_hold(int unit, const char *name)
{
struct g_gate_softc *sc = NULL;
@ -572,8 +572,8 @@ g_gate_ioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, struct threa
switch (bp->bio_cmd) {
case BIO_READ:
break;
case BIO_DELETE:
break;
case BIO_WRITE:
error = copyout(bp->bio_data, ggio->gctl_data,
bp->bio_length);