diff options
Diffstat (limited to 'src/window.c')
-rw-r--r-- | src/window.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/window.c b/src/window.c index 920a528a03e..b0171436088 100644 --- a/src/window.c +++ b/src/window.c @@ -5762,6 +5762,12 @@ zero means top of window, negative means relative to bottom of window. */) int this_scroll_margin; #endif + if (!(BUFFERP (w->buffer) + && XBUFFER (w->buffer) == current_buffer)) + /* This test is needed to make sure PT/PT_BYTE make sense in w->buffer + when passed below to set_marker_both. */ + error ("move-to-window-line called from unrelated buffer"); + window = selected_window; start = marker_position (w->start); if (start < BEGV || start > ZV) |