Fix SEGV on terminals without 'IC' capability (Yoshiaki Kasahara).
authorKaroly Lorentey <lorentey@elte.hu>
Sun, 6 Jun 2004 00:07:46 +0000 (00:07 +0000)
committerKaroly Lorentey <lorentey@elte.hu>
Sun, 6 Jun 2004 00:07:46 +0000 (00:07 +0000)
* src/term.c (tty_insert_glyphs): Added missing first parameter (contributed by
Yoshiaki Kasahara <kasahara@nc.kyushu-u.ac.jp>).
(encode_terminal_code): Converted to use ANSI prototype syntax.

git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-187

src/term.c

index 396a24d..a0e46f4 100644 (file)
@@ -619,12 +619,12 @@ tty_clear_end_of_line (struct frame *f, int first_unused_hpos)
    return value is the number of bytes store in DST.  */
 
 int
-encode_terminal_code (coding, src, dst, src_len, dst_len, consumed)
-     struct coding_system *coding;
-     struct glyph *src;
-     int src_len;
-     unsigned char *dst;
-     int dst_len, *consumed;
+encode_terminal_code (struct coding_system *coding,
+                      struct glyph *src,
+                      unsigned char *dst,
+                      int src_len,
+                      int dst_len,
+                      int *consumed)
 {
   struct glyph *src_start = src, *src_end = src + src_len;
   unsigned char *dst_start = dst, *dst_end = dst + dst_len;
@@ -895,7 +895,8 @@ tty_insert_glyphs (struct frame *f, struct glyph *start, int len)
 
          /* The size of conversion buffer (1024 bytes) is surely
             sufficient for just one glyph.  */
-         produced = encode_terminal_code (glyph, conversion_buffer, 1,
+         produced = encode_terminal_code (FRAME_TERMINAL_CODING (f),
+                                           glyph, conversion_buffer, 1,
                                           conversion_buffer_size, &consumed);
        }