Commit acb4e1d19e58daa7f81698af44c07fe3173da4fa

Stefan Sperling 2019-08-10T18:43:09

sync merge(1) fix diff from OpenRCS/OpenCVS

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
diff --git a/lib/diff3.c b/lib/diff3.c
index f9a22b0..89b27a7 100644
--- a/lib/diff3.c
+++ b/lib/diff3.c
@@ -541,7 +541,9 @@ ed_patch_lines(struct rcs_lines *dlines, struct rcs_lines *plines)
 				if (lp == NULL)
 					return -1;
 
-				if (lp->l_len == 2 && lp->l_line[0] == '.')
+				if (lp->l_len == 2 &&
+				    lp->l_line[0] == '.' &&
+				    lp->l_line[1] == '\n')
 					break;
 
 				TAILQ_REMOVE(&(plines->l_lines), lp, l_list);