diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-05-30 14:04:05 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-05-30 14:04:05 +0900 |
commit | 2f76ebc93ca6bfc2aba1be330aabe391a7d093d2 (patch) | |
tree | 2aba711da4a334aeaa374345e1714973d1e92315 /builtin/describe.c | |
parent | Merge branch 'sg/t6500-no-redirect-of-stdin' (diff) | |
parent | lock_file: move static locks into functions (diff) | |
download | tgif-2f76ebc93ca6bfc2aba1be330aabe391a7d093d2.tar.xz |
Merge branch 'ma/lockfile-cleanup'
Code clean-up to adjust to a more recent lockfile API convention that
allows lockfile instances kept on the stack.
* ma/lockfile-cleanup:
lock_file: move static locks into functions
lock_file: make function-local locks non-static
refs.c: do not die if locking fails in `delete_pseudoref()`
refs.c: do not die if locking fails in `write_pseudoref()`
t/helper/test-write-cache: clean up lock-handling
Diffstat (limited to 'builtin/describe.c')
-rw-r--r-- | builtin/describe.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/describe.c b/builtin/describe.c index a4160e7f5d..cf1ae77d7c 100644 --- a/builtin/describe.c +++ b/builtin/describe.c @@ -612,7 +612,7 @@ int cmd_describe(int argc, const char **argv, const char *prefix) suffix = broken; } } else if (dirty) { - static struct lock_file index_lock; + struct lock_file index_lock = LOCK_INIT; struct rev_info revs; struct argv_array args = ARGV_ARRAY_INIT; int fd, result; |