@matheusbsbs / matheus-bagliano / commits / 6844fc806a
Fork 0

Fix tracing when GIT_TRACE is set to an empty string.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <junkio@cox.net>

Christian Couder committed Oct 14, 2006 at 16:05 UTC 6844fc806ace7d7c31ad788a8886cfd0498ceec5
1 file changed +2 -1
trace.c
+2 -1
@@ -55,7 +55,8 @@ static int get_trace_fd(int *need_close)
55 {
56 char *trace = getenv("GIT_TRACE");
57
58 - if (!trace || !strcmp(trace, "0") || !strcasecmp(trace, "false"))
58 + if (!trace || !strcmp(trace, "") ||
59 + !strcmp(trace, "0") || !strcasecmp(trace, "false"))
60 return 0;
61 if (!strcmp(trace, "1") || !strcasecmp(trace, "true"))
62 return STDERR_FILENO;