summaryrefslogtreecommitdiff
path: root/usr.bin/wall
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2004-09-14 23:01:32 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2004-09-14 23:01:32 +0000
commitc0e973bc516f159de3f43293d3e433ea2954638b (patch)
tree5dfc49c69bc3618f60fe69222353db3fc4ab4828 /usr.bin/wall
parent18cc977f24d591996fe2f13cde4b6685f6590264 (diff)
arithmetic on void * not permitted
Diffstat (limited to 'usr.bin/wall')
-rw-r--r--usr.bin/wall/ttymsg.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/wall/ttymsg.c b/usr.bin/wall/ttymsg.c
index f95f8c24648..3059f9b1b9e 100644
--- a/usr.bin/wall/ttymsg.c
+++ b/usr.bin/wall/ttymsg.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ttymsg.c,v 1.14 2003/07/31 18:21:42 avsm Exp $ */
+/* $OpenBSD: ttymsg.c,v 1.15 2004/09/14 23:01:31 deraadt Exp $ */
/* $NetBSD: ttymsg.c,v 1.3 1994/11/17 07:17:55 jtc Exp $ */
/*
@@ -34,7 +34,7 @@
#if 0
static const char sccsid[] = "@(#)ttymsg.c 8.2 (Berkeley) 11/16/93";
#endif
-static const char rcsid[] = "$OpenBSD: ttymsg.c,v 1.14 2003/07/31 18:21:42 avsm Exp $";
+static const char rcsid[] = "$OpenBSD: ttymsg.c,v 1.15 2004/09/14 23:01:31 deraadt Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -132,7 +132,9 @@ ttymsg(iov, iovcnt, line, tmout)
--iovcnt;
}
if (wret) {
- iov->iov_base += wret;
+ char *base = iov->iov_base;
+
+ iov->iov_base = base + wret;
iov->iov_len -= wret;
}
continue;