From 28452655af988094792483a51d188c58137760cd Mon Sep 17 00:00:00 2001 From: Thomas Rast Date: Fri, 3 Aug 2012 14:16:24 +0200 Subject: diff_setup_done(): return void diff_setup_done() has historically returned an error code, but lost the last nonzero return in 943d5b7 (allow diff.renamelimit to be set regardless of -M/-C, 2006-08-09). The callers were in a pretty confused state: some actually checked for the return code, and some did not. Let it return void, and patch all callers to take this into account. This conveniently also gets rid of a handful of different(!) error messages that could never be triggered anyway. Note that the function can still die(). Signed-off-by: Thomas Rast Signed-off-by: Junio C Hamano --- tree-diff.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'tree-diff.c') diff --git a/tree-diff.c b/tree-diff.c index 28ad6db9f..f760740a1 100644 --- a/tree-diff.c +++ b/tree-diff.c @@ -212,8 +212,7 @@ static void try_to_follow_renames(struct tree_desc *t1, struct tree_desc *t2, co diff_opts.rename_score = opt->rename_score; paths[0] = NULL; diff_tree_setup_paths(paths, &diff_opts); - if (diff_setup_done(&diff_opts) < 0) - die("unable to set up diff options to follow renames"); + diff_setup_done(&diff_opts); diff_tree(t1, t2, base, &diff_opts); diffcore_std(&diff_opts); diff_tree_release_paths(&diff_opts); -- cgit v1.2.1