aboutsummaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorMichael Haggerty <mhagger@alum.mit.edu>2014-10-01 12:28:15 +0200
committerJunio C Hamano <gitster@pobox.com>2014-10-01 13:45:11 -0700
commit7108ad232fc7a4c889e82b40c52125adc9796ff5 (patch)
tree21a15d1fe052aa839d0b4f536da92695b74d0f1b /cache.h
parent0a06f148373285822baf5f3e83696732a556a2d1 (diff)
downloadgit-7108ad232fc7a4c889e82b40c52125adc9796ff5.tar.gz
git-7108ad232fc7a4c889e82b40c52125adc9796ff5.tar.xz
cache.h: define constants LOCK_SUFFIX and LOCK_SUFFIX_LEN
There are a few places that use these values, so define constants for them. Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index 0a76d023e..24891a81d 100644
--- a/cache.h
+++ b/cache.h
@@ -570,6 +570,10 @@ extern void fill_stat_cache_info(struct cache_entry *ce, struct stat *st);
#define REFRESH_IN_PORCELAIN 0x0020 /* user friendly output, not "needs update" */
extern int refresh_index(struct index_state *, unsigned int flags, const struct pathspec *pathspec, char *seen, const char *header_msg);
+/* String appended to a filename to derive the lockfile name: */
+#define LOCK_SUFFIX ".lock"
+#define LOCK_SUFFIX_LEN 5
+
struct lock_file {
struct lock_file *next;
int fd;