commit - 9f5da0913af47a525ab2a2422c7911cdb08866d0
commit + 4125b1eff8d9dfcd961dc70ebbd5d54c97bdc3f6
blob - 74b22eb8207ab2c5f154a22229051900a3d7b1ce
blob + b20dabf6658691770d21bfe3c1227ae815223474
--- lib/diff_output_unidiff.c
+++ lib/diff_output_unidiff.c
cc->left.end - chunk_end_line);
if (rc)
return rc;
+
+ rc = diff_output_trailing_newline_msg(outinfo, dest,
+ &result->chunks.head[result->chunks.len - 1]);
+ if (rc != DIFF_RC_OK)
+ return rc;
}
return DIFF_RC_OK;
blob - /dev/null
blob + dc9ca80aa498390f1b6acbcf3ac017176a05d4be (mode 644)
--- /dev/null
+++ test/expect125.diff
+--- test125.left.txt
++++ test125.right.txt
+@@ -1,7 +1,7 @@
+ This is a test
+ of missing trailing new lines
+ in context
+-this line has a change
++this line has the change
+ this is the same
+ this is too
+ and this one
+\ No newline at end of file
blob - /dev/null
blob + ecce2a6d7d492d0bd0090f27093c54a876d3dca6 (mode 644)
--- /dev/null
+++ test/test125.left.txt
+This is a test
+of missing trailing new lines
+in context
+this line has a change
+this is the same
+this is too
+and this one
\ No newline at end of file
blob - /dev/null
blob + 1242106e06a77ee483209c2b43420bc94a7de383 (mode 644)
--- /dev/null
+++ test/test125.right.txt
+This is a test
+of missing trailing new lines
+in context
+this line has the change
+this is the same
+this is too
+and this one
\ No newline at end of file