I recently rebuilt my Atton Emacs Editor on ArchLinux. All works fine but when logged in via a remove ssh session I have noticed that some parts of the display dont update correctly. I have narrowed this down to the behaviour of addch() when used in a loop. The following code should print 60 * on the first line of the window, but only 1 * is displayed. If you set the loop to only 6 it will print 6*s. It appears that callig addch() in a loop floods a buffer somewhere in the stack.
#include <curses.h>
int main(void)
{
int i=1;
initscr();
move(0,0);
for (i = 1; i <= 60; i++)
addch('*');
refresh();
getch();
endwin();
}
Anyone any ideas how to make this work without having to add lots of coding to work round it ?