diff options
author | Clive Lin <clive@FreeBSD.org> | 2001-06-25 18:33:34 +0000 |
---|---|---|
committer | Clive Lin <clive@FreeBSD.org> | 2001-06-25 18:33:34 +0000 |
commit | 1af9373f21a83a668cb39f51eb74c225a78333b5 (patch) | |
tree | 02eec38f3d7005c182f9cff1d803fd8902a1a320 /chinese/tin/files/patch-cook.c | |
parent | Initial import of acpicatools. (diff) |
Disable wrap_lines in put_cooked().
Enlarge buffer size for extra-long line.
This fixes core dump which is rarely happened.
PR: ports/26961
Submitted by: Yen-Ming Lee <leeym@cae.ce.ntu.edu.tw>
Diffstat (limited to 'chinese/tin/files/patch-cook.c')
-rw-r--r-- | chinese/tin/files/patch-cook.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/chinese/tin/files/patch-cook.c b/chinese/tin/files/patch-cook.c index 7584b8b4cd65..2a554fae80f5 100644 --- a/chinese/tin/files/patch-cook.c +++ b/chinese/tin/files/patch-cook.c @@ -1,5 +1,5 @@ ---- src/cook.c.orig Sat Sep 23 14:34:20 2000 -+++ src/cook.c Sat Sep 23 14:34:41 2000 +--- src/cook.c.orig Mon Feb 19 22:59:13 2001 ++++ src/cook.c Mon Apr 30 02:57:21 2001 @@ -109,7 +109,7 @@ while (i++ < j) *q++ = ' '; @@ -9,3 +9,11 @@ *q++ = '^'; *q++ = ((*p) & 0xFF) + '@'; if (*p == '\f') /* ^L detected */ +@@ -147,6 +147,7 @@ + vsnprintf (buf, sizeof(buf) - 1, fmt, ap); + + bufp = buf; ++ wrap_lines = FALSE; + + for (p = bufp; *p; p++) { + if (*p == '\n' || ((overflow + p - bufp >= cCOLS) && wrap_lines)) { |