]> code.delx.au - gnu-emacs/blobdiff - src/xdisp.c
automatically generated from GPLed version
[gnu-emacs] / src / xdisp.c
index 3f89898d389545aeb535fca32b393737659f733e..d7c0bfe34bc3f9cb4da56167ea6afad7d11f3e40 100644 (file)
@@ -1,5 +1,6 @@
 /* Display generation from window structure and buffer text.
-   Copyright (C) 1985, 86, 87, 88, 93, 94, 95 Free Software Foundation, Inc.
+   Copyright (C) 1985, 86, 87, 88, 93, 94, 95, 1997
+     Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -417,7 +418,8 @@ message2_nolog (m, len)
       if (noninteractive_need_newline)
        putc ('\n', stderr);
       noninteractive_need_newline = 0;
-      fwrite (m, len, 1, stderr);
+      if (m)
+       fwrite (m, len, 1, stderr);
       if (cursor_in_echo_area == 0)
        fprintf (stderr, "\n");
       fflush (stderr);
@@ -647,11 +649,13 @@ echo_area_display ()
             i < vpos + XFASTINT (XWINDOW (mini_window)->height); i++)
          {
            get_display_line (f, i, 0);
+           /* We don't use FRAME_SCROLL_BAR_WIDTH (f) as the starting
+              hpos, because it is good to clear whatever is behind the
+              scroll bar.  This does not affect the scroll bar itself.  */
            display_string (XWINDOW (mini_window), i,
                            "", 0, 
-                            FRAME_LEFT_SCROLL_BAR_WIDTH (f),
-                           0, 0, 0,
-                           FRAME_WIDTH (f) + FRAME_LEFT_SCROLL_BAR_WIDTH (f));
+                            0, 0, 0,
+                            0, FRAME_WIDTH (f) + FRAME_SCROLL_BAR_WIDTH (f));
          }
       }
     }
@@ -2989,7 +2993,7 @@ display_text_line (w, start, vpos, hpos, taboffset, ovstr_done)
   next_boundary = pos;
   p1prev = p1;
   prevpos = pos;
-  while (1)
+  while (p1 < endp)
     {
       if (pos >= pause)
        {
@@ -4437,7 +4441,7 @@ decode_mode_spec (w, c, spec_width, maxwidth)
       /* coding-system (including end-of-line type) */
       {
        int eol_flag = (c == 'Z');
-       char *p;
+       char *p = decode_mode_spec_buf;
 
        if (FRAME_TERMCAP_P (f))
          {
@@ -4447,7 +4451,7 @@ decode_mode_spec (w, c, spec_width, maxwidth)
            p = decode_mode_spec_coding (terminal_coding.symbol, p, 0);
          }
        p = decode_mode_spec_coding (b->buffer_file_coding_system,
-                                    decode_mode_spec_buf, eol_flag);
+                                    p, eol_flag);
 
 #if 0 /* This proves to be annoying; I think we can do without.  -- rms.  */
 #ifdef subprocesses