@matheusbsbs / matheus-bagliano / commits / b90ced0f7d
Fork 0

builtin-apply: stronger indent-with-on-tab fixing

Fix any sequence of 8 spaces in initial indent, not just the case where the 8 spaces are the first thing on the line. Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>

J. Bruce Fields committed Dec 16, 2007 at 12:58 UTC b90ced0f7da0b8dcdac1aabd8840a23daef25b43
1 file changed +1 -2
builtin-apply.c
+1 -2
@@ -1587,8 +1587,7 @@ static int apply_line(char *output, const char *patch, int plen,
1587 } else if (ch == ' ') {
1588 last_space_in_indent = i;
1589 if ((ws_rule & WS_INDENT_WITH_NON_TAB) &&
1590 - last_tab_in_indent <= 0 &&
1591 - 8 <= i)
1590 + 8 <= i - last_tab_in_indent)
1591 need_fix_leading_space = 1;
1592 }
1593 else