Accepting request 708976 from devel:tools:scm
OBS-URL: https://build.opensuse.org/request/show/708976 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/git?expand=0&rev=233
This commit is contained in:
parent
df05c6eeae
commit
09b049c67a
Binary file not shown.
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8ccb1ce743ee991d91697e163c47c11be4bf81efbdd9fb0b4a7ad77cc0020d28
|
||||
size 5491296
|
BIN
git-2.22.0.tar.sign
Normal file
BIN
git-2.22.0.tar.sign
Normal file
Binary file not shown.
3
git-2.22.0.tar.xz
Normal file
3
git-2.22.0.tar.xz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:159e4b599f8af4612e70b666600a3139541f8bacc18124daf2cbe8d1b934f29f
|
||||
size 5609772
|
34
git.changes
34
git.changes
@ -1,3 +1,37 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Jun 10 14:04:52 UTC 2019 - Marketa Calabkova <mcalabkova@suse.com>
|
||||
|
||||
- git 2.22.0
|
||||
* The filter specification "--filter=sparse:path=<path>" used to
|
||||
create a lazy/partial clone has been removed. Using a blob that is
|
||||
part of the project as sparse specification is still supported with
|
||||
the "--filter=sparse:oid=<blob>" option
|
||||
* "git checkout --no-overlay" can be used to trigger a new mode of
|
||||
checking out paths out of the tree-ish, that allows paths that
|
||||
match the pathspec that are in the current index and working tree
|
||||
and are not in the tree-ish.
|
||||
* Four new configuration variables {author,committer}.{name,email}
|
||||
have been introduced to override user.{name,email} in more specific
|
||||
cases.
|
||||
* "git branch" learned a new subcommand "--show-current".
|
||||
* The command line completion (in contrib/) has been taught to
|
||||
complete more subcommand parameters.
|
||||
* The completion helper code now pays attention to repository-local
|
||||
configuration (when available), which allows --list-cmds to honour
|
||||
a repository specific setting of completion.commands, for example.
|
||||
* The list of conflicted paths shown in the editor while concluding a
|
||||
conflicted merge was shown above the scissors line when the
|
||||
clean-up mode is set to "scissors", even though it was commented
|
||||
out just like the list of updated paths and other information to
|
||||
help the user explain the merge better.
|
||||
* "git rebase" that was reimplemented in C did not set ORIG_HEAD
|
||||
correctly, which has been corrected.
|
||||
* "git worktree add" used to do a "find an available name with stat
|
||||
and then mkdir", which is race-prone. This has been fixed by using
|
||||
mkdir and reacting to EEXIST in a loop.
|
||||
- Removed upstreamed patch worktree-fix-worktree-add-race.patch
|
||||
* previous item
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 8 17:02:10 UTC 2019 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
|
4
git.spec
4
git.spec
@ -30,7 +30,7 @@
|
||||
%bcond_without git_libsecret
|
||||
%bcond_without docs
|
||||
Name: git
|
||||
Version: 2.21.0
|
||||
Version: 2.22.0
|
||||
Release: 0
|
||||
Summary: Fast, scalable, distributed revision control system
|
||||
License: GPL-2.0-only
|
||||
@ -54,7 +54,6 @@ Patch6: git-tcsh-completion-fixes.diff
|
||||
# adapt paths in zsh completion (bnc#853183)
|
||||
Patch7: git-zsh-completion-fixes.diff
|
||||
Patch8: git-asciidoc.patch
|
||||
Patch9: worktree-fix-worktree-add-race.patch
|
||||
Patch10: setup-don-t-fail-if-commondir-reference-is-deleted.patch
|
||||
Patch11: 0001-DOC-Move-to-DocBook-5-when-using-asciidoctor.patch
|
||||
BuildRequires: curl
|
||||
@ -291,7 +290,6 @@ directory /git/ that calls the cgi script.
|
||||
%patch6 -p1
|
||||
%patch7 -p1
|
||||
%patch8 -p1
|
||||
%patch9 -p1
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
|
||||
|
@ -1,63 +0,0 @@
|
||||
From e134801d570d0a0c85424eb80b41893f4d8383ca Mon Sep 17 00:00:00 2001
|
||||
From: Michal Suchanek <msuchanek@suse.de>
|
||||
Date: Wed, 13 Feb 2019 10:40:42 +0100
|
||||
Subject: [PATCH] worktree: fix worktree add race.
|
||||
|
||||
Git runs a stat loop to find a worktree name that's available and then does
|
||||
mkdir on the found name. Turn it to mkdir loop to avoid another invocation of
|
||||
worktree add finding the same free name and creating the directory first.
|
||||
|
||||
Signed-off-by: Michal Suchanek <msuchanek@suse.de>
|
||||
---
|
||||
v2:
|
||||
- simplify loop exit condition
|
||||
- exit early if the mkdir fails for reason other than already present
|
||||
worktree
|
||||
- make counter unsigned
|
||||
---
|
||||
builtin/worktree.c | 12 +++++++-----
|
||||
1 file changed, 7 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/builtin/worktree.c b/builtin/worktree.c
|
||||
index 3f9907fcc994..85a604cfe98c 100644
|
||||
--- a/builtin/worktree.c
|
||||
+++ b/builtin/worktree.c
|
||||
@@ -268,10 +268,10 @@ static int add_worktree(const char *path, const char *refname,
|
||||
struct strbuf sb_git = STRBUF_INIT, sb_repo = STRBUF_INIT;
|
||||
struct strbuf sb = STRBUF_INIT;
|
||||
const char *name;
|
||||
- struct stat st;
|
||||
struct child_process cp = CHILD_PROCESS_INIT;
|
||||
struct argv_array child_env = ARGV_ARRAY_INIT;
|
||||
- int counter = 0, len, ret;
|
||||
+ unsigned int counter = 0;
|
||||
+ int len, ret;
|
||||
struct strbuf symref = STRBUF_INIT;
|
||||
struct commit *commit = NULL;
|
||||
int is_branch = 0;
|
||||
@@ -295,8 +295,12 @@ static int add_worktree(const char *path, const char *refname,
|
||||
if (safe_create_leading_directories_const(sb_repo.buf))
|
||||
die_errno(_("could not create leading directories of '%s'"),
|
||||
sb_repo.buf);
|
||||
- while (!stat(sb_repo.buf, &st)) {
|
||||
+
|
||||
+ while (mkdir(sb_repo.buf, 0777)) {
|
||||
counter++;
|
||||
+ if ((errno != EEXIST) || !counter /* overflow */)
|
||||
+ die_errno(_("could not create directory of '%s'"),
|
||||
+ sb_repo.buf);
|
||||
strbuf_setlen(&sb_repo, len);
|
||||
strbuf_addf(&sb_repo, "%d", counter);
|
||||
}
|
||||
@@ -306,8 +310,6 @@ static int add_worktree(const char *path, const char *refname,
|
||||
atexit(remove_junk);
|
||||
sigchain_push_common(remove_junk_on_signal);
|
||||
|
||||
- if (mkdir(sb_repo.buf, 0777))
|
||||
- die_errno(_("could not create directory of '%s'"), sb_repo.buf);
|
||||
junk_git_dir = xstrdup(sb_repo.buf);
|
||||
is_junk = 1;
|
||||
|
||||
--
|
||||
2.20.1
|
||||
|
Loading…
Reference in New Issue
Block a user