lock_file: make function-local locks non-static
[gitweb.git] / builtin / describe.c
index e4869df7b434845544dfcc0c37cae6a77cd42dad..8933aa969c67cd6407bb0fcc6755f19f546ca792 100644 (file)
@@ -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;