fix an off-by-one in tog's draw_file() causing wrong diff output This issue caused empty lines added in diffs to be displayed without leading + in the diff view. Problem found by op@ ok op jamsek
diff --git a/tog/tog.c b/tog/tog.c
index 61e731b..1900350 100644
--- a/tog/tog.c
+++ b/tog/tog.c
@@ -3242,7 +3242,7 @@ draw_file(struct tog_view *view, const char *header)
free(line);
return err;
}
- if (view->x < width - 1)
+ if (view->x < width)
waddwstr(view->window, wline + view->x);
free(wline);
wline = NULL;