diff options
author | Jiang Xin <worldhello.net@gmail.com> | 2012-03-16 20:18:07 +0800 |
---|---|---|
committer | Jiang Xin <worldhello.net@gmail.com> | 2012-03-16 20:18:07 +0800 |
commit | d90b16ed421eb51fc4d7c6bda5f3332cc2e3aece (patch) | |
tree | 2d90d25ecbe794492f0fb267f31af8a1f646327d /builtin | |
parent | l10n: Improve zh_CN translation for msg "not something we can merge" (diff) | |
parent | Git 1.7.10-rc1 (diff) | |
download | tgif-d90b16ed421eb51fc4d7c6bda5f3332cc2e3aece.tar.xz |
Merge v1.7.10-rc0 for git l10n update
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/prune-packed.c | 4 | ||||
-rw-r--r-- | builtin/prune.c | 2 | ||||
-rw-r--r-- | builtin/verify-tag.c | 10 |
3 files changed, 12 insertions, 4 deletions
diff --git a/builtin/prune-packed.c b/builtin/prune-packed.c index f9463deec2..b58a2e1eb2 100644 --- a/builtin/prune-packed.c +++ b/builtin/prune-packed.c @@ -35,8 +35,6 @@ static void prune_dir(int i, DIR *dir, char *pathname, int len, int opts) unlink_or_warn(pathname); display_progress(progress, i + 1); } - pathname[len] = 0; - rmdir(pathname); } void prune_packed_objects(int opts) @@ -65,6 +63,8 @@ void prune_packed_objects(int opts) continue; prune_dir(i, d, pathname, len + 3, opts); closedir(d); + pathname[len + 2] = '\0'; + rmdir(pathname); } stop_progress(&progress); } diff --git a/builtin/prune.c b/builtin/prune.c index 58d7cb8324..b99b635e44 100644 --- a/builtin/prune.c +++ b/builtin/prune.c @@ -85,9 +85,9 @@ static int prune_dir(int i, char *path) } fprintf(stderr, "bad sha1 file: %s/%s\n", path, de->d_name); } + closedir(dir); if (!show_only) rmdir(path); - closedir(dir); return 0; } diff --git a/builtin/verify-tag.c b/builtin/verify-tag.c index 28c2174338..986789f706 100644 --- a/builtin/verify-tag.c +++ b/builtin/verify-tag.c @@ -58,6 +58,14 @@ static int verify_tag(const char *name, int verbose) return ret; } +static int git_verify_tag_config(const char *var, const char *value, void *cb) +{ + int status = git_gpg_config(var, value, cb); + if (status) + return status; + return git_default_config(var, value, cb); +} + int cmd_verify_tag(int argc, const char **argv, const char *prefix) { int i = 1, verbose = 0, had_error = 0; @@ -66,7 +74,7 @@ int cmd_verify_tag(int argc, const char **argv, const char *prefix) OPT_END() }; - git_config(git_default_config, NULL); + git_config(git_verify_tag_config, NULL); argc = parse_options(argc, argv, prefix, verify_tag_options, verify_tag_usage, PARSE_OPT_KEEP_ARGV0); |