# [PATCH 1/1] git: remove redundant getenv() in init-db

1 messages from 2005-04-14 to 2005-04-14. Participants: tony.luck@intel.com.
Thread: https://gitlist.dev/t/18

## tony.luck@intel.com, 2005-04-14 18:30

Subject: [PATCH 1/1] git: remove redundant getenv() in init-db
Message-ID: <200504141830.j3EIUL003768@unix-os.sc.intel.com>
URL: https://gitlist.dev/e/200504141830.j3EIUL003768%40unix-os.sc.intel.com

```
From: Tony Luck <tony.luck@intel.com>

init-db calls getenv(DB_ENVIRONMENT) twice.  Once should be enough.

Signed-off-by: Tony Luck <tony.luck@intel.com>

---

 init-db.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

--- init-db.c
+++ init-db.c	2005-04-14 11:01:52.000000000 -0700
@@ -7,7 +7,7 @@
 
 int main(int argc, char **argv)
 {
-	char *sha1_dir = getenv(DB_ENVIRONMENT), *path;
+	char *sha1_dir, *path;
 	int len, i;
 
 	if (mkdir(".git", 0755) < 0) {

```
