diff options
author | Alex Riesen <raa.lkml@gmail.com> | 2008-09-26 08:21:39 -0700 |
---|---|---|
committer | Shawn O. Pearce <spearce@spearce.org> | 2008-09-26 08:24:19 -0700 |
commit | eb53586ba94087d9750c58d29ff494e5c1a95207 (patch) | |
tree | fbee35a827cde50ddf13aa1add0df0a7386b0f94 /merge-recursive.c | |
parent | ed520a8f270253f4a779aece1352b10fb9a689de (diff) | |
download | git-eb53586ba94087d9750c58d29ff494e5c1a95207.tar.gz |
Cleanup remove_path
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'merge-recursive.c')
-rw-r--r-- | merge-recursive.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/merge-recursive.c b/merge-recursive.c index dbdb9ac2c4..ac90fd9e27 100644 --- a/merge-recursive.c +++ b/merge-recursive.c @@ -394,12 +394,10 @@ static int update_stages(const char *path, struct diff_filespec *o, static int remove_path(const char *name) { - int ret; char *slash, *dirs; - ret = unlink(name); - if (ret) - return ret; + if (unlink(name)) + return -1; dirs = xstrdup(name); while ((slash = strrchr(name, '/'))) { *slash = '\0'; @@ -407,7 +405,7 @@ static int remove_path(const char *name) break; } free(dirs); - return ret; + return 0; } static int remove_file(struct merge_options *o, int clean, |