diff options
author | peter <peter@FreeBSD.org> | 1999-05-06 18:44:42 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1999-05-06 18:44:42 +0000 |
commit | 459d4a2cc5e6111860f2c6a86117a230d98dd4e9 (patch) | |
tree | 3ebec15b9f996d9b97c11ef575d325c41cea11f1 /sys/dev/mse/mse.c | |
parent | daa969b0667e983bbabc44c8ddcda321b70523c5 (diff) | |
download | FreeBSD-src-459d4a2cc5e6111860f2c6a86117a230d98dd4e9.zip FreeBSD-src-459d4a2cc5e6111860f2c6a86117a230d98dd4e9.tar.gz |
Fix up a few easy 'assignment used as truth value' and 'suggest parens
around && within ||' type warnings. I'm pretty sure I have not masked
any problems here, I've committed real problem fixes seperately.
Diffstat (limited to 'sys/dev/mse/mse.c')
-rw-r--r-- | sys/dev/mse/mse.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/dev/mse/mse.c b/sys/dev/mse/mse.c index 001da0c..e952af0 100644 --- a/sys/dev/mse/mse.c +++ b/sys/dev/mse/mse.c @@ -11,7 +11,7 @@ * this software for any purpose. It is provided "as is" * without express or implied warranty. * - * $Id: mse.c,v 1.40 1999/04/28 10:52:43 dt Exp $ + * $Id: mse.c,v 1.41 1999/05/06 18:12:28 peter Exp $ */ /* * Driver for the Logitech and ATI Inport Bus mice for use with 386bsd and @@ -357,8 +357,9 @@ mseread(dev, uio, ioflag) return (0); } sc->sc_flags |= MSESC_WANT; - if (error = tsleep((caddr_t)sc, MSEPRI | PCATCH, - "mseread", 0)) { + error = tsleep((caddr_t)sc, MSEPRI | PCATCH, + "mseread", 0); + if (error) { splx(s); return (error); } @@ -391,7 +392,8 @@ mseread(dev, uio, ioflag) } splx(s); xfer = min(uio->uio_resid, sc->mode.packetsize - sc->sc_bytesread); - if (error = uiomove(&sc->sc_bytes[sc->sc_bytesread], xfer, uio)) + error = uiomove(&sc->sc_bytes[sc->sc_bytesread], xfer, uio); + if (error) return (error); sc->sc_bytesread += xfer; return(0); |