@matheusbsbs / matheus-bagliano / commits / 047fbe906b
Fork 0

builtin-diff: turn recursive on when defaulting to --patch format.

Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Jul 1, 2006 at 22:15 UTC 047fbe906b375e8a3a7564ad0e4443f62dd528a2
1 file changed +3 -1
builtin-diff.c
+3 -1
@@ -254,8 +254,10 @@ int cmd_diff(int argc, const char **argv, char **envp)
254 init_revisions(&rev);
255
256 argc = setup_revisions(argc, argv, &rev, NULL);
257 - if (!rev.diffopt.output_format)
257 + if (!rev.diffopt.output_format) {
258 rev.diffopt.output_format = DIFF_FORMAT_PATCH;
259 + diff_setup_done(&rev.diffopt);
260 + }
261
262 /* Do we have --cached and not have a pending object, then
263 * default to HEAD by hand. Eek.