summaryrefslogtreecommitdiff
path: root/src/quickfix.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-09-05 17:03:40 +0200
committerBram Moolenaar <Bram@vim.org>2020-09-05 17:03:40 +0200
commit59941cbd8035415d68683edc4e571306b10669ad (patch)
tree5006831992654145681761ef48fe74918000589f /src/quickfix.c
parent2ce14589f210dcb3d17d1d80285256f8ac10abab (diff)
downloadvim-git-59941cbd8035415d68683edc4e571306b10669ad.tar.gz
patch 8.2.1599: missing line end when skipping a long line with :cgetfilev8.2.1599
Problem: Missing line end when skipping a long line with :cgetfile. Solution: Fix off-by-one error. (closes #6870)
Diffstat (limited to 'src/quickfix.c')
-rw-r--r--src/quickfix.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quickfix.c b/src/quickfix.c
index f8ff7765e..09d5d8fa0 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -810,7 +810,7 @@ qf_get_next_file_line(qfstate_T *state)
// reached.
if (fgets((char *)IObuff, IOSIZE, state->fd) == NULL
|| (int)STRLEN(IObuff) < IOSIZE - 1
- || IObuff[IOSIZE - 1] == '\n')
+ || IObuff[IOSIZE - 2] == '\n')
break;
}