зеркало из https://github.com/microsoft/git.git
Fix crash when GIT_DIR is invalid
We used to test if a pointer was NULL, and if it was, try to access it. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Родитель
7e18e56920
Коммит
3a3c3fc42a
2
setup.c
2
setup.c
|
@ -184,7 +184,7 @@ const char *setup_git_directory_gently(int *nongit_ok)
|
|||
}
|
||||
return NULL;
|
||||
bad_dir_environ:
|
||||
if (!nongit_ok) {
|
||||
if (nongit_ok) {
|
||||
*nongit_ok = 1;
|
||||
return NULL;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче