summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-02-09 04:38:22 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-02-11 21:11:36 (GMT)
commitcc1816b0d64a2aa3d6c32d642c3b403f8625c484 (patch)
tree9294e271fa9b17f8831ef03ad7a042ffe0fd386c
parentb26768e25685b4f575ae07a38e5180b9879bd01e (diff)
downloadgit-cc1816b0d64a2aa3d6c32d642c3b403f8625c484.zip
git-cc1816b0d64a2aa3d6c32d642c3b403f8625c484.tar.gz
git-cc1816b0d64a2aa3d6c32d642c3b403f8625c484.tar.bz2
archive-tar.c: guard config parser from value=NULL
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--archive-tar.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/archive-tar.c b/archive-tar.c
index e1bced5..30aa2e2 100644
--- a/archive-tar.c
+++ b/archive-tar.c
@@ -222,7 +222,7 @@ static void write_global_extended_header(const unsigned char *sha1)
static int git_tar_config(const char *var, const char *value)
{
if (!strcmp(var, "tar.umask")) {
- if (!strcmp(value, "user")) {
+ if (value && !strcmp(value, "user")) {
tar_umask = umask(0);
umask(tar_umask);
} else {