mirror of
https://github.com/git/git
synced 2024-08-25 02:35:46 +00:00
sparse-checkout: use extern for global variables
When the core.sparseCheckoutCone config setting was added in
879321eb0b
("sparse-checkout: add 'cone' mode" 2019-11-21), the
variables storing the config values for core.sparseCheckout and
core.sparseCheckoutCone were rearranged in cache.h, but in doing
so the "extern" keyword was dropped.
While we are tending to drop the "extern" keyword for function
declarations, it is still necessary for global variables used
across multiple *.c files. The impact of not having the extern
keyword may be unpredictable.
Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
761e3d26bb
commit
44143583b7
4
cache.h
4
cache.h
|
@ -925,8 +925,8 @@ extern int protect_hfs;
|
|||
extern int protect_ntfs;
|
||||
extern const char *core_fsmonitor;
|
||||
|
||||
int core_apply_sparse_checkout;
|
||||
int core_sparse_checkout_cone;
|
||||
extern int core_apply_sparse_checkout;
|
||||
extern int core_sparse_checkout_cone;
|
||||
|
||||
/*
|
||||
* Include broken refs in all ref iterations, which will
|
||||
|
|
Loading…
Reference in a new issue