{"thread":{"id":"5121","subject":"[PATCH] Fix crash when GIT_DIR is invalid","startedAt":"2006-08-04T15:46:19Z","lastAt":"2006-08-04T22:42:27Z","messageCount":3,"participants":["Johannes Schindelin","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"24708","messageId":"Pine.LNX.4.63.0608041745500.1800@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"5121","inReplyTo":null,"subject":"[PATCH] Fix crash when GIT_DIR is invalid","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-08-04T15:46:19Z","receivedAt":"2006-08-04T15:46:19Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"\nWe used to test if a pointer was NULL, and if it was, try to access it.\n\nSigned-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n---\n setup.c |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/setup.c b/setup.c\nindex 358e139..2afdba4 100644\n--- a/setup.c\n+++ b/setup.c\n@@ -184,7 +184,7 @@ const char *setup_git_directory_gently(i\n \t\t}\n \t\treturn NULL;\n \tbad_dir_environ:\n-\t\tif (!nongit_ok) {\n+\t\tif (nongit_ok) {\n \t\t\t*nongit_ok = 1;\n \t\t\treturn NULL;\n \t\t}\n-- \n1.4.2.rc2.g0bca-dirty\n"},{"id":"24732","messageId":"7virl8jpnw.fsf@assigned-by-dhcp.cox.net","threadId":"5121","inReplyTo":"Pine.LNX.4.63.0608041745500.1800@wbgn013.biozentrum.uni-wuerzburg.de","subject":"Re: [PATCH] Fix crash when GIT_DIR is invalid","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-08-04T18:56:19Z","receivedAt":"2006-08-04T18:56:19Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n>  \tbad_dir_environ:\n> -\t\tif (!nongit_ok) {\n> +\t\tif (nongit_ok) {\n>  \t\t\t*nongit_ok = 1;\n\n*BLUSH*  How could I have missed something like this...\n\nThanks.\n"},{"id":"24768","messageId":"Pine.LNX.4.63.0608050041230.1800@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"5121","inReplyTo":"7virl8jpnw.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH] Fix crash when GIT_DIR is invalid","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-08-04T22:42:27Z","receivedAt":"2006-08-04T22:42:27Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Fri, 4 Aug 2006, Junio C Hamano wrote:\n\n> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n> \n> >  \tbad_dir_environ:\n> > -\t\tif (!nongit_ok) {\n> > +\t\tif (nongit_ok) {\n> >  \t\t\t*nongit_ok = 1;\n> \n> *BLUSH*  How could I have missed something like this...\n\nIt's too easy. I actually reviewed that patch, saw that I did the same \n(not!), and hit the bug...\n\nCiao,\nDscho \"errare humanum est\" --\n"}]}