diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-09-19 21:20:48 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-09-19 21:20:48 +0000 |
commit | d65c51c0c2a74ed8add720f20b47538cbb6e042e (patch) | |
tree | 813b0f442475dd47c37a7717ecbc4ce1dda0bcff /usr.bin | |
parent | d6b619f594979f8e582dbf32a96fe67dacfad03a (diff) |
do not += snprintf; andrushock@korovino.net
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mg/basic.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/mg/basic.c b/usr.bin/mg/basic.c index ca16df09b74..7495e5b2d82 100644 --- a/usr.bin/mg/basic.c +++ b/usr.bin/mg/basic.c @@ -1,4 +1,4 @@ -/* $OpenBSD: basic.c,v 1.14 2003/05/16 19:28:59 vincent Exp $ */ +/* $OpenBSD: basic.c,v 1.15 2003/09/19 21:20:47 deraadt Exp $ */ /* * Basic cursor motion commands. @@ -239,8 +239,9 @@ getgoal(LINE *dlp) col++; else { char tmp[5]; - col += snprintf(tmp, sizeof tmp, "\\%o", - c); + + snprintf(tmp, sizeof tmp, "\\%o", c); + col += strlen(tmp); } if (col > curgoal) break; |