]> Kevux Git Server - rit/commitdiff
refs: add REFS_STORE_ALL_CAPS
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>
Mon, 24 Apr 2017 10:01:21 +0000 (17:01 +0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 25 Apr 2017 04:28:55 +0000 (21:28 -0700)
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c
refs/refs-internal.h

diff --git a/refs.c b/refs.c
index 96eba92..6e6f0ec 100644 (file)
--- a/refs.c
+++ b/refs.c
@@ -1526,11 +1526,7 @@ struct ref_store *get_main_ref_store(void)
        if (main_ref_store)
                return main_ref_store;
 
-       main_ref_store = ref_store_init(get_git_dir(),
-                                       (REF_STORE_READ |
-                                        REF_STORE_WRITE |
-                                        REF_STORE_ODB |
-                                        REF_STORE_MAIN));
+       main_ref_store = ref_store_init(get_git_dir(), REF_STORE_ALL_CAPS);
        return main_ref_store;
 }
 
index 6904986..b26f7e4 100644 (file)
@@ -467,6 +467,10 @@ struct ref_store;
 #define REF_STORE_WRITE                (1 << 1) /* can perform update operations */
 #define REF_STORE_ODB          (1 << 2) /* has access to object database */
 #define REF_STORE_MAIN         (1 << 3)
+#define REF_STORE_ALL_CAPS     (REF_STORE_READ | \
+                                REF_STORE_WRITE | \
+                                REF_STORE_ODB | \
+                                REF_STORE_MAIN)
 
 /*
  * Initialize the ref_store for the specified gitdir. These functions