git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Git 1.6.5-rc git clone unhandled exception using http protocol

From
Junio C Hamano <gitster@pobox.com>
Date
Oct 13, 2009, 21:06 UTC
Message-ID
<7v4oq3uhp2.fsf@alter.siamese.dyndns.org>
In-Reply-To
<d2e97e800910130443m56ea2850nf72274fc55a4be68@mail.gmail.com>
Michael Wookey <michaelwookey@gmail.com> writes:
Show 40 quoted lines
> 2009/10/13 Johannes Sixt <j.sixt@viscovery.net>:
>> Michael Wookey schrieb:
>>> Using the above repository, I see the same crash with msysGit at git
>>> revision 1.6.5. Using windbg as the post-mortem debugger, the
>>> following information is captured:
>>> [ ... snip ... ]
>> Wow, this is great work, thank you very much! The function is
>> strip_path_suffix(). And here is a patch that fixes the crash.
>>
>> --- >8 ---
>> From: Johannes Sixt <j6t@kdbg.org>
>> Subject: [PATCH] remote-curl: add missing initialization of argv0_path
>>
>> All programs, in particular also the stand-alone programs (non-builtins)
>> must call git_extract_argv0_path(argv[0]) in order to help builds that
>> derive the installation prefix at runtime, such as the MinGW build.
>> Without this call, the program segfaults (or raises an assertion
>> failure).
>>
>> Signed-off-by: Johannes Sixt <j6t@kdbg.org>
>> ---
>>  remote-curl.c |    1 +
>>  1 files changed, 1 insertions(+), 0 deletions(-)
>>
>> diff --git a/remote-curl.c b/remote-curl.c
>> index ad6a163..d8d276a 100644
>> --- a/remote-curl.c
>> +++ b/remote-curl.c
>> @@ -82,6 +82,7 @@ int main(int argc, const char **argv)
>>        const char *url;
>>        struct walker *walker = NULL;
>>
>> +       git_extract_argv0_path(argv[0]);
>>        setup_git_directory();
>>        if (argc < 2) {
>>                fprintf(stderr, "Remote needed\n");
>> --
>> 1.6.5.1024.g31034.dirty
>
> No more crashes for me :)
Beautiful.  Thanks, both of you!
Previous: Michael Wookey
Message 12 of 12 in “Git 1.6.5-rc git clone unhandled exception using http protocol”
  1. eduard stefanOct 9, 2009
  2. Tay Ray ChuanOct 10, 2009
  3. eduard stefanOct 10, 2009
  4. Tay Ray ChuanOct 10, 2009
  5. eduard stefanOct 10, 2009
  6. Tay Ray ChuanOct 10, 2009
  7. eduard stefanOct 11, 2009
  8. eduard stefanOct 13, 2009
  9. Michael WookeyOct 13, 2009
  10. Johannes SixtOct 13, 2009
  11. Michael WookeyOct 13, 2009
  12. Junio C HamanoOct 13, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.