jcs
/amend
/amendments
/202
patch: Account for newline
jcs made amendment 202 3 days ago
--- patch.c Wed Dec 17 20:39:06 2025
+++ patch.c Sun Oct 4 12:57:56 2026
@@ -109,7 +109,7 @@ patch_process(struct repo *repo, Str255 filename, shor
patch_state = PATCH_STATE_HEADER_FROM;
- for (i = 0; i < patch_size; i += linelen) {
+ for (i = 0; i < patch_size; i += linelen + 1) {
linelen = FSReadLine(patch_frefnum, buf, sizeof(buf) - 1);
if (linelen < 0)
break;