Git development
 help / color / mirror / Atom feed
From: "Joy Gundu via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: "Patrick Steinhardt>" <ps@pks.im>,
	"Kristoffer Haugsbakk>" <kristofferhaugsbakk@fastmail.com>,
	"Christian Couder>" <christian.couder@gmail.com>,
	"Usman Akinyemi>" <usmanakinyemi202@gmail.com>,
	Joie Joie <soniqjjj@gmail.com>, Joy <soniqjjj@gmail.com>,
	Joy Gundu <soniqjjj@gmail.com>
Subject: [PATCH v2 1/2] repo: zero-initialize configuration values
Date: Thu, 22 Oct 2026 09:47:11 +0000	[thread overview]
Message-ID: <df93a2a86cae7d342270c0ee67a1c0d41ada202e.1792662432.git.gitgitgadget@gmail.com> (raw)
In-Reply-To: <pull.2271.v2.git.1792662432.gitgitgadget@gmail.com>

From: Joy Gundu <soniqjjj@gmail.com>

Signed-off-by: Joy Gundu <soniqjjj@gmail.com>
---
 environment.c | 14 ++------------
 1 file changed, 2 insertions(+), 12 deletions(-)

diff --git a/environment.c b/environment.c
index c83cf44839..89af09aa40 100644
--- a/environment.c
+++ b/environment.c
@@ -752,34 +752,24 @@ int git_default_config(const char *var, const char *value,
 
 void repo_config_values_init(struct repo_config_values *cfg)
 {
+	memset(cfg, 0, sizeof(*cfg));
+
 	/* section "core" config values */
-	cfg->attributes_file = NULL;
-	cfg->excludes_file = NULL;
-	cfg->editor_program = NULL;
-	cfg->pager_program = NULL;
-	cfg->askpass_program = NULL;
-	cfg->apply_default_whitespace = NULL;
-	cfg->apply_default_ignorewhitespace = NULL;
 	cfg->push_default = PUSH_DEFAULT_UNSPECIFIED;
 	cfg->autorebase = AUTOREBASE_NEVER;
 	cfg->object_creation_mode = OBJECT_CREATION_MODE;
-	cfg->apply_sparse_checkout = 0;
 	cfg->trust_ctime = 1;
 	cfg->check_stat = 1;
 	cfg->zlib_compression_level = Z_BEST_SPEED;
 	cfg->pack_compression_level = Z_DEFAULT_COMPRESSION;
 	cfg->precomposed_unicode = -1; /* see probe_utf8_pathname_composition() */
-	cfg->core_sparse_checkout_cone = 0;
 	cfg->warn_on_object_refname_ambiguity = 1;
 	cfg->protect_hfs = PROTECT_HFS_DEFAULT;
 	cfg->protect_ntfs = PROTECT_NTFS_DEFAULT;
-	cfg->ignore_case = 0;
 	cfg->trust_executable_bit = 1;
 	cfg->has_symlinks = platform_has_symlinks();
-	cfg->use_nanosec = 0;
 
 	/* section "sparse" config values */
-	cfg->sparse_expect_files_outside_of_patterns = 0;
 
 	/* section "branch" config values */
 	cfg->branch_track = BRANCH_TRACK_REMOTE;
-- 
gitgitgadget


  reply	other threads:[~2026-10-22  9:47 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-20 18:56 [PATCH] config: move pack size limit into repo config Joy via GitGitGadget
2026-10-20 19:02 ` Kristoffer Haugsbakk
2026-10-21  8:09 ` Patrick Steinhardt
2026-10-21 12:23   ` Joie Joie
2026-10-22  9:47 ` [PATCH v2 0/2] " Joy via GitGitGadget
2026-10-22  9:47   ` Joy Gundu via GitGitGadget [this message]
2026-10-22 11:30     ` [PATCH v2 1/2] repo: zero-initialize configuration values Patrick Steinhardt
2026-10-23 12:00       ` Joie Joie
2026-10-26  7:30         ` Patrick Steinhardt
2026-10-22  9:47   ` [PATCH v2 2/2] config: move pack size limit into repo config Joy Gundu via GitGitGadget
2026-10-22 11:30     ` Patrick Steinhardt
2026-10-22 11:30   ` [PATCH v2 0/2] " Patrick Steinhardt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=df93a2a86cae7d342270c0ee67a1c0d41ada202e.1792662432.git.gitgitgadget@gmail.com \
    --to=gitgitgadget@gmail.com \
    --cc=christian.couder@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=kristofferhaugsbakk@fastmail.com \
    --cc=ps@pks.im \
    --cc=soniqjjj@gmail.com \
    --cc=usmanakinyemi202@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox