Commit 230a75fc authored by Karl Heuer's avatar Karl Heuer

(Fvertical_motion): Use window arg, not selected_window.

parent 36f41915
......@@ -860,8 +860,7 @@ Returns number of lines moved; may be closer to zero than LINES\n\
Lisp_Object lines, window;
{
struct position pos;
register struct window *w = XWINDOW (selected_window);
int width = window_internal_width (w) - 1;
register struct window *w;
CHECK_NUMBER (lines, 0);
if (! NILP (window))
......@@ -869,7 +868,8 @@ Returns number of lines moved; may be closer to zero than LINES\n\
else
XSET (window, Lisp_Window, selected_window);
pos = *vmotion (point, XINT (lines), width,
w = XWINDOW (window);
pos = *vmotion (point, XINT (lines), window_internal_width (w) - 1,
/* Not XFASTINT since perhaps could be negative */
XINT (w->hscroll), window);
......
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