summaryrefslogtreecommitdiffstats
path: root/sys/dev/rp
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1999-05-06 18:44:42 +0000
committerpeter <peter@FreeBSD.org>1999-05-06 18:44:42 +0000
commit459d4a2cc5e6111860f2c6a86117a230d98dd4e9 (patch)
tree3ebec15b9f996d9b97c11ef575d325c41cea11f1 /sys/dev/rp
parentdaa969b0667e983bbabc44c8ddcda321b70523c5 (diff)
downloadFreeBSD-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/rp')
-rw-r--r--sys/dev/rp/rp.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/dev/rp/rp.c b/sys/dev/rp/rp.c
index 39972dd..410a857 100644
--- a/sys/dev/rp/rp.c
+++ b/sys/dev/rp/rp.c
@@ -29,7 +29,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: rp.c,v 1.23 1999/04/24 20:26:12 billf Exp $
+ * $Id: rp.c,v 1.24 1999/04/27 11:15:12 phk Exp $
*/
/*
@@ -1555,10 +1555,9 @@ rpwrite(dev, uio, flag)
tp = rp->rp_tty;
while(rp->rp_disable_writes) {
rp->rp_waiting = 1;
- if(error = ttysleep(tp, (caddr_t)rp, TTOPRI|PCATCH,
- "rp_write", 0)) {
+ error = ttysleep(tp, (caddr_t)rp, TTOPRI|PCATCH, "rp_write", 0);
+ if (error)
return(error);
- }
}
error = (*linesw[tp->t_line].l_write)(tp, uio, flag);
@@ -1661,7 +1660,7 @@ rpioctl(dev, cmd, data, flag, p)
dt->c_lflag = (tp->t_lflag & lt->c_lflag)
| (dt->c_lflag & ~lt->c_lflag);
for(cc = 0; cc < NCCS; ++cc)
- if(lt->c_cc[cc] = tp->t_cc[cc])
+ if((lt->c_cc[cc] = tp->t_cc[cc]) != 0)
dt->c_cc[cc] = tp->t_cc[cc];
if(lt->c_ispeed != 0)
dt->c_ispeed = tp->t_ispeed;
OpenPOWER on IntegriCloud