diff options
author | Kenichi Handa <handa@m17n.org> | 2003-08-21 11:36:40 +0000 |
---|---|---|
committer | Kenichi Handa <handa@m17n.org> | 2003-08-21 11:36:40 +0000 |
commit | f730033e6c12eeb6d4d12778bb9ddc3d02e99653 (patch) | |
tree | ed8bca427196a0321606e1d08d1188d794513c53 /src | |
parent | 3dd3a50226507bd4a832c70c711df9f159c9ab10 (diff) | |
download | emacs-f730033e6c12eeb6d4d12778bb9ddc3d02e99653.tar.gz |
(term_init): Fix previous change
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 5 | ||||
-rw-r--r-- | src/term.c | 8 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 07963de9e1b..fc8ce43d766 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2003-08-21 Kenichi Handa <handa@m17n.org> + + * term.c (term_init): Fix previous change; don't rely on the + length of `buffer' if TERMINFO is defined. + 2003-08-20 Dave Love <fx@gnu.org> * atimer.h: Include lisp.h. diff --git a/src/term.c b/src/term.c index 506fc16ffb3..bae059ea439 100644 --- a/src/term.c +++ b/src/term.c @@ -2229,14 +2229,12 @@ to do `unset TERMCAP' (C-shell: `unsetenv TERMCAP') as well.", #endif } -#ifdef TERMINFO - area = (char *) xmalloc (buffer_size); -#else +#ifndef TERMINFO if (strlen (buffer) >= buffer_size) abort (); - - area = (char *) xmalloc (strlen (buffer)); + buffer_size = strlen (buffer); #endif + area = (char *) xmalloc (buffer_size); TS_ins_line = tgetstr ("al", address); TS_ins_multi_lines = tgetstr ("AL", address); |