From 3e7b066e2229f45d633164beaeb8815b0973a9b4 Mon Sep 17 00:00:00 2001 From: Michael Haggerty Date: Tue, 17 Dec 2013 14:43:58 +0100 Subject: [PATCH 1/2] cmd_repack(): remove redundant local variable "nr_packs" Its value is the same as the number of entries in the "names" string_list, so just use "names.nr" in its place. Signed-off-by: Michael Haggerty Acked-by: Stefan Beller Signed-off-by: Junio C Hamano --- builtin/repack.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/builtin/repack.c b/builtin/repack.c index a0ff5c704..91e2363c7 100644 --- a/builtin/repack.c +++ b/builtin/repack.c @@ -123,7 +123,7 @@ int cmd_repack(int argc, const char **argv, const char *prefix) struct string_list rollback = STRING_LIST_INIT_NODUP; struct string_list existing_packs = STRING_LIST_INIT_DUP; struct strbuf line = STRBUF_INIT; - int nr_packs, ext, ret, failed; + int ext, ret, failed; FILE *out; /* variables to be filled by option parsing */ @@ -233,13 +233,11 @@ int cmd_repack(int argc, const char **argv, const char *prefix) if (ret) return ret; - nr_packs = 0; out = xfdopen(cmd.out, "r"); while (strbuf_getline(&line, out, '\n') != EOF) { if (line.len != 40) die("repack: Expecting 40 character sha1 lines only from pack-objects."); string_list_append(&names, line.buf); - nr_packs++; } fclose(out); ret = finish_command(&cmd); @@ -247,7 +245,7 @@ int cmd_repack(int argc, const char **argv, const char *prefix) return ret; argv_array_clear(&cmd_args); - if (!nr_packs && !quiet) + if (!names.nr && !quiet) printf("Nothing new to pack.\n"); /* From 5512ac5840c8bcaa487806cf402ff960091ab244 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 17 Dec 2013 11:42:12 -0800 Subject: [PATCH 2/2] Git 1.8.5.2 Signed-off-by: Junio C Hamano --- Documentation/RelNotes/1.8.5.2.txt | 20 ++++++++++++++++++++ Documentation/git.txt | 3 ++- GIT-VERSION-GEN | 2 +- RelNotes | 2 +- 4 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 Documentation/RelNotes/1.8.5.2.txt diff --git a/Documentation/RelNotes/1.8.5.2.txt b/Documentation/RelNotes/1.8.5.2.txt new file mode 100644 index 000000000..3ac4984f1 --- /dev/null +++ b/Documentation/RelNotes/1.8.5.2.txt @@ -0,0 +1,20 @@ +Git v1.8.5.2 Release Notes +========================== + +Fixes since v1.8.5.1 +-------------------- + + * "git diff -- ':(icase)makefile'" was unnecessarily rejected at the + command line parser. + + * "git cat-file --batch-check=ok" did not check the existence of + the named object. + + * "git am --abort" sometimes complained about not being able to write + a tree with an 0{40} object in it. + + * Two processes creating loose objects at the same time could have + failed unnecessarily when the name of their new objects started + with the same byte value, due to a race condition. + +Also contains typofixes, documentation updates and trivial code clean-ups. diff --git a/Documentation/git.txt b/Documentation/git.txt index 4448ce270..cc0e5e2bf 100644 --- a/Documentation/git.txt +++ b/Documentation/git.txt @@ -43,9 +43,10 @@ unreleased) version of Git, that is available from 'master' branch of the `git.git` repository. Documentation for older releases are available here: -* link:v1.8.5.1/git.html[documentation for release 1.8.5.1] +* link:v1.8.5.2/git.html[documentation for release 1.8.5.2] * release notes for + link:RelNotes/1.8.5.2.txt[1.8.5.2], link:RelNotes/1.8.5.1.txt[1.8.5.1], link:RelNotes/1.8.5.txt[1.8.5]. diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN index 6dd0ec127..0ec4d003f 100755 --- a/GIT-VERSION-GEN +++ b/GIT-VERSION-GEN @@ -1,7 +1,7 @@ #!/bin/sh GVF=GIT-VERSION-FILE -DEF_VER=v1.8.5.1 +DEF_VER=v1.8.5.2 LF=' ' diff --git a/RelNotes b/RelNotes index 0064299c0..1efc120fe 120000 --- a/RelNotes +++ b/RelNotes @@ -1 +1 @@ -Documentation/RelNotes/1.8.5.1.txt \ No newline at end of file +Documentation/RelNotes/1.8.5.2.txt \ No newline at end of file