Commit cb4545ad authored by Eli Zaretskii's avatar Eli Zaretskii
Browse files

Fix redisplay bugs due to uninitialized glyphs in frame glyph pool.

 dispnew.c (realloc_glyph_pool): Zero out newly allocated glyphs.
 msdos.c (IT_display_cursor): Log cursor position on termscript.
 .gdbinit (pgx): Display the avoid_cursor_p flag.
parent 0613f5d5
...@@ -535,6 +535,9 @@ define pgx ...@@ -535,6 +535,9 @@ define pgx
if ($g->overlaps_vertically_p) if ($g->overlaps_vertically_p)
printf " OVL" printf " OVL"
end end
if ($g->avoid_cursor_p)
printf " AVOID"
end
if ($g->left_box_line_p) if ($g->left_box_line_p)
printf " [" printf " ["
end end
......
2010-08-06 Eli Zaretskii <eliz@gnu.org>
* dispnew.c (realloc_glyph_pool): Zero out newly allocated glyphs.
* msdos.c (IT_display_cursor): Log cursor position on termscript.
* .gdbinit (pgx): Display the avoid_cursor_p flag.
2010-08-06 Dan Nicolaescu <dann@ics.uci.edu> 2010-08-06 Dan Nicolaescu <dann@ics.uci.edu>
   
* process.c: Remove HAVE_SOCKETS #ifdefs inside #ifdef * process.c: Remove HAVE_SOCKETS #ifdefs inside #ifdef
......
...@@ -1528,7 +1528,11 @@ realloc_glyph_pool (struct glyph_pool *pool, struct dim matrix_dim) ...@@ -1528,7 +1528,11 @@ realloc_glyph_pool (struct glyph_pool *pool, struct dim matrix_dim)
int size = needed * sizeof (struct glyph); int size = needed * sizeof (struct glyph);
if (pool->glyphs) if (pool->glyphs)
pool->glyphs = (struct glyph *) xrealloc (pool->glyphs, size); {
pool->glyphs = (struct glyph *) xrealloc (pool->glyphs, size);
memset (pool->glyphs + pool->nglyphs, 0,
size - pool->nglyphs * sizeof (struct glyph));
}
else else
{ {
pool->glyphs = (struct glyph *) xmalloc (size); pool->glyphs = (struct glyph *) xmalloc (size);
......
...@@ -1593,14 +1593,16 @@ IT_display_cursor (int on) ...@@ -1593,14 +1593,16 @@ IT_display_cursor (int on)
ScreenSetCursor (current_pos_Y, current_pos_X); ScreenSetCursor (current_pos_Y, current_pos_X);
cursor_cleared = 0; cursor_cleared = 0;
if (tty->termscript) if (tty->termscript)
fprintf (tty->termscript, "\nCURSOR ON"); fprintf (tty->termscript, "\nCURSOR ON (%dx%d)",
current_pos_Y, current_pos_X);
} }
else if (!on && !cursor_cleared) else if (!on && !cursor_cleared)
{ {
ScreenSetCursor (-1, -1); ScreenSetCursor (-1, -1);
cursor_cleared = 1; cursor_cleared = 1;
if (tty->termscript) if (tty->termscript)
fprintf (tty->termscript, "\nCURSOR OFF"); fprintf (tty->termscript, "\nCURSOR OFF (%dx%d)",
current_pos_Y, current_pos_X);
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment