diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2014-11-01 04:03:23 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2014-11-01 04:03:23 +0000 |
commit | 34ae1ecac770351286cf8f4fcbba75e803615564 (patch) | |
tree | f7a20ff63bece883cee2c575490f800a23d61e9f /usr.bin/mandoc/term.c | |
parent | 5204c430460ebe028353bd8d46e4c583e5d716af (diff) |
fix a typo causing crashes in Unicode string length measurement
Diffstat (limited to 'usr.bin/mandoc/term.c')
-rw-r--r-- | usr.bin/mandoc/term.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/mandoc/term.c b/usr.bin/mandoc/term.c index 9193f192cda..8ff50bf20aa 100644 --- a/usr.bin/mandoc/term.c +++ b/usr.bin/mandoc/term.c @@ -1,4 +1,4 @@ -/* $OpenBSD: term.c,v 1.93 2014/10/29 00:17:01 schwarze Exp $ */ +/* $OpenBSD: term.c,v 1.94 2014/11/01 04:03:22 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010-2014 Ingo Schwarze <schwarze@openbsd.org> @@ -682,7 +682,7 @@ term_strlen(const struct termp *p, const char *cp) switch (esc) { case ESCAPE_UNICODE: - uc = mchars_num2uc(seq + 1, sz - 1); + uc = mchars_num2uc(seq + 1, ssz - 1); break; case ESCAPE_NUMBERED: uc = mchars_num2char(seq, ssz); |