summaryrefslogtreecommitdiff
path: root/ident.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2012-05-21 23:09:57 (GMT)
committerJunio C Hamano <gitster@pobox.com>2012-05-22 16:07:53 (GMT)
commit2d4b4fcebdd4fb8c8cd2664b390e3bbb82370155 (patch)
treeb0114961bbebbe74b99d67f9672348dcba5fc871 /ident.c
parent9597921b6c173d90359e2cfa4c2e36de8d1554e6 (diff)
downloadgit-2d4b4fcebdd4fb8c8cd2664b390e3bbb82370155.zip
git-2d4b4fcebdd4fb8c8cd2664b390e3bbb82370155.tar.gz
git-2d4b4fcebdd4fb8c8cd2664b390e3bbb82370155.tar.bz2
move git_default_* variables to ident.c
There's no reason anybody outside of ident.c should access these directly (they should use the new accessors which make sure the variables are initialized), so we can make them file-scope statics. While we're at it, move user_ident_explicitly_given into ident.c; while still globally visible, it makes more sense to reside with the ident code. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'ident.c')
-rw-r--r--ident.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ident.c b/ident.c
index bb1158f..af92b2c 100644
--- a/ident.c
+++ b/ident.c
@@ -7,7 +7,11 @@
*/
#include "cache.h"
+#define MAX_GITNAME (1000)
+static char git_default_name[MAX_GITNAME];
+static char git_default_email[MAX_GITNAME];
static char git_default_date[50];
+int user_ident_explicitly_given;
#ifdef NO_GECOS_IN_PWENT
#define get_gecos(ignored) "&"