--- emacs24-24.4+1.orig/src/cm.c 2014-10-21 23:45:42.000000000 +0200 +++ /dev/shm/cm.c 2016-08-03 15:10:55.803193217 +0200 @@ -327,10 +327,12 @@ char *p; const char *dcm; +#if 0 /* First the degenerate case */ if (row == curY (tty) && col == curX (tty)) /* already there */ return; - +#endif // XXX MODEM + if (curY (tty) >= 0 && curX (tty) >= 0) { /* We may have quick ways to go to the upper-left, bottom-left, @@ -375,7 +377,7 @@ * In the following comparison, the = in <= is because when the costs * are the same, it looks nicer (I think) to move directly there. */ - if (directcost <= relcost) + if (directcost <= relcost || 1) // XXX MODEM { /* compute REAL direct cost */ cost = 0; @@ -383,14 +385,14 @@ ? tgoto (dcm, row, col) : tgoto (dcm, col, row)); emacs_tputs (tty, p, 1, evalcost); - if (cost <= relcost) + if (cost <= relcost || 1) // XXX MODEM { /* really is cheaper */ emacs_tputs (tty, p, 1, cmputc); curY (tty) = row, curX (tty) = col; return; } } - + switch (use) { case USEHOME: