diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/window.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/window.c b/src/window.c index 3f115260adf..83440f440cc 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -4147,9 +4147,11 @@ window_scroll_pixel_based (window, n, whole, noerror) | |||
| 4147 | else | 4147 | else |
| 4148 | move_it_by_lines (&it, n, 1); | 4148 | move_it_by_lines (&it, n, 1); |
| 4149 | 4149 | ||
| 4150 | /* End if we end up at ZV or BEGV. */ | 4150 | /* We failed if we find ZV is already on the screen (scrolling up, |
| 4151 | means there's nothing past the end), or if we can't start any | ||
| 4152 | earlier (scrolling down, means there's nothing past the top). */ | ||
| 4151 | if ((n > 0 && IT_CHARPOS (it) == ZV) | 4153 | if ((n > 0 && IT_CHARPOS (it) == ZV) |
| 4152 | || (n < 0 && IT_CHARPOS (it) == BEGV)) | 4154 | || (n < 0 && IT_CHARPOS (it) == CHARPOS (start))) |
| 4153 | { | 4155 | { |
| 4154 | if (IT_CHARPOS (it) == ZV) | 4156 | if (IT_CHARPOS (it) == ZV) |
| 4155 | { | 4157 | { |