* Git 1.6.5-rc git clone unhandled exception using http protocol @ 2009-10-09 17:27 eduard stefan 2009-10-10 10:55 ` Tay Ray Chuan 0 siblings, 1 reply; 12+ messages in thread From: eduard stefan @ 2009-10-09 17:27 UTC (permalink / raw) To: Git Mailing List I've tried Git 1.6.5 release candidates (rc1, rc2, rc3) with msysGit, and "git clone git://github.com/loudej/spark.git" it's working, but "git clone http://github.com/loudej/spark.git" crashes with an Win32 unhandled exception. I have tried to create an empty repository and run both "git remote-curl http://github.com/loudej/spark.git" and "git remote-curl" , but it crashes with the same error. How can I obtain more information about the error? BTW, Git 1.6.4.4 is working over both protocols, on Windows Server 2008 SP2 x86, using the same msysGit (msysGit-fullinstall-1.6.4-preview20090729.exe). Have a nice day, A. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-09 17:27 Git 1.6.5-rc git clone unhandled exception using http protocol eduard stefan @ 2009-10-10 10:55 ` Tay Ray Chuan [not found] ` <4AD09F5E.9090304@gmail.com> 0 siblings, 1 reply; 12+ messages in thread From: Tay Ray Chuan @ 2009-10-10 10:55 UTC (permalink / raw) To: eduard stefan; +Cc: Git Mailing List Hi, On Sat, Oct 10, 2009 at 1:27 AM, eduard stefan <eduard.stefan@gmail.com> wrote: > How can I obtain more information about the error? How are you executing the git commands? From the windows command line? From the msys bash shell? Could you copy and paste the output of git when cloning the repo? How about the win32 exception? What does it say? Does it display as a dialog? -- Cheers, Ray Chuan ^ permalink raw reply [flat|nested] 12+ messages in thread
[parent not found: <4AD09F5E.9090304@gmail.com>]
[parent not found: <be6fef0d0910100811l325d3df1jdf8d3d9dd51e3385@mail.gmail.com>]
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol [not found] ` <be6fef0d0910100811l325d3df1jdf8d3d9dd51e3385@mail.gmail.com> @ 2009-10-10 15:55 ` eduard stefan 2009-10-10 16:07 ` Tay Ray Chuan 0 siblings, 1 reply; 12+ messages in thread From: eduard stefan @ 2009-10-10 15:55 UTC (permalink / raw) To: Tay Ray Chuan; +Cc: Git Mailing List [-- Attachment #1: Type: text/plain, Size: 720 bytes --] Tay Ray Chuan wrote: > Hi, > > On Sat, Oct 10, 2009 at 10:51 PM, eduard stefan <eduard.stefan@gmail.com> wrote: >> I attached three screenshots of the msys shell, >> it doesn't matter what url is used, >> and git remote-curl doesn't crash when run in a non-git repository, >> but as soon as I create an empty repo, it crashes just like git clone http://... > > that's not how you use remote-curl. > > Cloning a bogus repository (http://test.com/sample.git) isn't a good idea too. I was just trying to point that the URL used is not relevant, as long as the protocol used is URL, then it crashes. > Could you show me the screenshot of you cloning > http://github.com/loudej/spark.git? Done. Have a nice day, A. [-- Attachment #2: git-clone-1.png --] [-- Type: image/png, Size: 15141 bytes --] [-- Attachment #3: git-clone-2.png --] [-- Type: image/png, Size: 17283 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-10 15:55 ` eduard stefan @ 2009-10-10 16:07 ` Tay Ray Chuan 2009-10-10 16:52 ` eduard stefan 0 siblings, 1 reply; 12+ messages in thread From: Tay Ray Chuan @ 2009-10-10 16:07 UTC (permalink / raw) To: eduard stefan; +Cc: Git Mailing List Hi, On Sat, Oct 10, 2009 at 11:55 PM, eduard stefan <eduard.stefan@gmail.com> wrote: > I was just trying to point that the URL used is not relevant, > as long as the protocol used is URL, then it crashes. ok. I suspect, as you do, it's got to do with remote-curl. Could you try this command? echo list | git remote-curl http://github.com/loudej/spark.git On my machine, I get @refs/heads/master HEAD f192d3de483f2e7f38eebf84c8f1bbc8c4b5f185 refs/heads/gh-pages 2a0cd31d8706ec2d8cc5d7b49873cc24621b20af refs/heads/installers 10526926014eb2d89c2b449f1e29f4df7ab620bd refs/heads/master 7f36b2caf2f01566bd58f9304d6ad5c36ae280ce refs/heads/mono 80fc2424ebf082265c66bd6e0637c74744742b49 refs/heads/spark-1.1 62d62d5c183dd22cdf9491999291047add05c722 refs/heads/spike-1.1 d85abb61563e7f4f372c7e0418da0f20c49baf48 refs/tags/v1.0.39890-RC1 db9d3380c39284695added69edab46c2ddab2f48 refs/tags/v1.0.39917-RC2 70c418dd806a4eb7f32fa6fe710c9a5967ddef32 refs/tags/v1.0.39935 -- Cheers, Ray Chuan ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-10 16:07 ` Tay Ray Chuan @ 2009-10-10 16:52 ` eduard stefan 2009-10-10 22:54 ` Tay Ray Chuan 2009-10-13 10:10 ` Git 1.6.5-rc " Michael Wookey 0 siblings, 2 replies; 12+ messages in thread From: eduard stefan @ 2009-10-10 16:52 UTC (permalink / raw) To: Tay Ray Chuan, Git Mailing List Tay Ray Chuan wrote: > I suspect, as you do, it's got to do with remote-curl. > > Could you try this command? > > echo list | git remote-curl http://github.com/loudej/spark.git Inside an empty repository it crashes the same way, without any additional information. "git remote-curl" crashes in the same way, but "git remote-curl --help" tries to launch the browser. Is there any way to obtain more information from this crash? Some debug mode? Have a nice day, A. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-10 16:52 ` eduard stefan @ 2009-10-10 22:54 ` Tay Ray Chuan 2009-10-11 21:12 ` eduard stefan 2009-10-13 10:10 ` Git 1.6.5-rc " Michael Wookey 1 sibling, 1 reply; 12+ messages in thread From: Tay Ray Chuan @ 2009-10-10 22:54 UTC (permalink / raw) To: eduard stefan; +Cc: Git Mailing List, msysgit Hi, On Sun, Oct 11, 2009 at 12:52 AM, eduard stefan <eduard.stefan@gmail.com> wrote: > Tay Ray Chuan wrote: >> I suspect, as you do, it's got to do with remote-curl. >> >> Could you try this command? >> >> echo list | git remote-curl http://github.com/loudej/spark.git > > Inside an empty repository it crashes the same way, > without any additional information. > "git remote-curl" crashes in the same way, > but "git remote-curl --help" tries to launch the browser. just to check, running echo list | git remote-curl http://github.com/loudej/spark.git and git clone http://github.com/loudej/spark.git both gives the same error message: An unhandled win32 exception occurred in git-remote-curl.exe [5820]. Just-In-Time debugging this exception failed with the following error: No installed debugger has Just-In-Time debugging enabled. In Visual Studio, Just-In-Time debugging can be enabled from Tools/Options/Debugging/Just-In-Time. Check the documentation index for 'Just-in-time debugging, errors' for more information. in a dialog? > Is there any way to obtain more information from this crash? > Some debug mode? I'm assuming you're using the Microsoft Visual Studio development tools to compile git from the source. I'm cc'ing this to the msysgit mailing list, perhaps someone familiar with them can advise you further. -- Cheers, Ray Chuan ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-10 22:54 ` Tay Ray Chuan @ 2009-10-11 21:12 ` eduard stefan 2009-10-13 3:36 ` Git 1.6.5 " eduard stefan 0 siblings, 1 reply; 12+ messages in thread From: eduard stefan @ 2009-10-11 21:12 UTC (permalink / raw) To: Tay Ray Chuan; +Cc: Git Mailing List, msysgit Tay Ray Chuan wrote: > just to check, running > > echo list | git remote-curl http://github.com/loudej/spark.git > > and > > git clone http://github.com/loudej/spark.git > > both gives the same error message: > > An unhandled win32 exception occurred in git-remote-curl.exe [5820]. > Just-In-Time debugging this exception failed with the following > error: No installed debugger has Just-In-Time debugging enabled. In > Visual Studio, Just-In-Time debugging can be enabled from > Tools/Options/Debugging/Just-In-Time. > > Check the documentation index for 'Just-in-time debugging, errors' > for more information. > > in a dialog? > >> Is there any way to obtain more information from this crash? >> Some debug mode? > > I'm assuming you're using the Microsoft Visual Studio development > tools to compile git from the source. I'm cc'ing this to the msysgit > mailing list, perhaps someone familiar with them can advise you > further. > Git was compiled with msysGit, the errors are generated inside msysGit shell, and VS2008 debugger gives this message: "Unhandled exception at 0x00420354 in git-remote-curl.exe: 0xC0000005: Access violation reading location 0x00000000." Have a nice day, Eduard ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5 git clone unhandled exception using http protocol 2009-10-11 21:12 ` eduard stefan @ 2009-10-13 3:36 ` eduard stefan 0 siblings, 0 replies; 12+ messages in thread From: eduard stefan @ 2009-10-13 3:36 UTC (permalink / raw) Cc: Git Mailing List, msysgit > Git was compiled with msysGit, the errors are generated inside msysGit shell, > and VS2008 debugger gives this message: > > "Unhandled exception at 0x00420354 in git-remote-curl.exe: > 0xC0000005: Access violation reading location 0x00000000." As a sidenote, 1.6.5 release crashes the same way. After applying Shawn O. Pearce "Return of smart HTTP" patch series, it no longer crashes, and "git clone http://github.com/loudej/spark.git" returns "error: Unable to get pack file http://github.com/loudej/spark.git/objects/pack/ pack-1bc121e71e2847622f814603ddb34444bfc6a16c.pack The requested URL returned error: 502" which seems to be more like a GitHub problem. OTOH, cloning a local repositor serverd with mongoose works as expected: "git clone http://192.168.194.24/test.git/" Have a nice day, Eduard ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-10 16:52 ` eduard stefan 2009-10-10 22:54 ` Tay Ray Chuan @ 2009-10-13 10:10 ` Michael Wookey 2009-10-13 10:53 ` Johannes Sixt 1 sibling, 1 reply; 12+ messages in thread From: Michael Wookey @ 2009-10-13 10:10 UTC (permalink / raw) To: eduard stefan; +Cc: Tay Ray Chuan, Git Mailing List, msysgit, Junio C Hamano 2009/10/11 eduard stefan <eduard.stefan@gmail.com>: > Tay Ray Chuan wrote: >> I suspect, as you do, it's got to do with remote-curl. >> >> Could you try this command? >> >> echo list | git remote-curl http://github.com/loudej/spark.git > > Inside an empty repository it crashes the same way, > without any additional information. > "git remote-curl" crashes in the same way, > but "git remote-curl --help" tries to launch the browser. > > Is there any way to obtain more information from this crash? > Some debug mode? 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: (a14.e8c): Access violation - code c0000005 (!!! second chance !!!) eax=00000000 ebx=00000000 ecx=ffffffff edx=0046cc00 esi=0046f98f edi=00000000 eip=00420354 esp=0022fd80 ebp=0022fda8 iopl=0 nv up ei pl zr na pe nc cs=001b ss=0023 ds=0023 es=0023 fs=003b gs=0000 efl=00010246 ...and the faulting instruction is: git_remote_curl+0x20354: 00420354 f2ae repne scas byte ptr es:[edi] so, a NULL dereference. The initial disassembly of the function is this: 0:000> u 0042033C git_remote_curl+0x2033c: 0042033c 55 push ebp 0042033d 89e5 mov ebp,esp 0042033f 57 push edi 00420340 56 push esi 00420341 53 push ebx 00420342 83ec1c sub esp,1Ch 00420345 8b5d08 mov ebx,dword ptr [ebp+8] 00420348 8b750c mov esi,dword ptr [ebp+0Ch] 0042034b 31c0 xor eax,eax 0042034d b9ffffffff mov ecx,0FFFFFFFFh 00420352 89df mov edi,ebx 00420354 f2ae repne scas byte ptr es:[edi] 00420356 f7d1 not ecx 00420358 8d51ff lea edx,[ecx-1] 0042035b b9ffffffff mov ecx,0FFFFFFFFh 00420360 89f7 mov edi,esi 00420362 f2ae repne scas byte ptr es:[edi] 00420364 f7d1 not ecx 00420366 49 dec ecx 00420367 7466 je git_remote_curl+0x203cf (004203cf) 00420369 85d2 test edx,edx 0042036b 0f84b1000000 je git_remote_curl+0x20422 (00420422) 00420371 89f7 mov edi,esi 00420373 89de mov esi,ebx ... So its the first parameter that is NULL. The second parameter is: 0:000> da poi(ebp+c) 0046f98f "libexec/git-core" I don't know how to build msysGit so that symbols are generated so I've attempted to reconstruct the source code; which ends up looking something like the following: int some_unknown_func(char *arg1, char *arg2) { len1 = strlen(arg1) - 1; // <- crash here len2 = strlen(arg2); len3 = len2 - 1; if (len2 != 1) { if (!len1) return 0; for (;;) { x = arg1[len1 - 1]; if (x != '/' && x != '\\') { --len1; --len3; if (arg1[len1] != arg2[len3]) return 0; } else { ... } } } } Perhaps those more familiar with git's sources might recognise code that looks similar to the above sequence. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-13 10:10 ` Git 1.6.5-rc " Michael Wookey @ 2009-10-13 10:53 ` Johannes Sixt 2009-10-13 11:43 ` Michael Wookey 0 siblings, 1 reply; 12+ messages in thread From: Johannes Sixt @ 2009-10-13 10:53 UTC (permalink / raw) To: Michael Wookey, Junio C Hamano Cc: eduard stefan, Tay Ray Chuan, Git Mailing List, msysgit 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: > > (a14.e8c): Access violation - code c0000005 (!!! second chance !!!) > eax=00000000 ebx=00000000 ecx=ffffffff edx=0046cc00 esi=0046f98f edi=00000000 > eip=00420354 esp=0022fd80 ebp=0022fda8 iopl=0 nv up ei pl zr na pe nc > cs=001b ss=0023 ds=0023 es=0023 fs=003b gs=0000 efl=00010246 > > ...and the faulting instruction is: > > git_remote_curl+0x20354: > 00420354 f2ae repne scas byte ptr es:[edi] > > so, a NULL dereference. The initial disassembly of the function is this: > > 0:000> u 0042033C > git_remote_curl+0x2033c: > 0042033c 55 push ebp > 0042033d 89e5 mov ebp,esp > 0042033f 57 push edi > 00420340 56 push esi > 00420341 53 push ebx > 00420342 83ec1c sub esp,1Ch > 00420345 8b5d08 mov ebx,dword ptr [ebp+8] > 00420348 8b750c mov esi,dword ptr [ebp+0Ch] > 0042034b 31c0 xor eax,eax > 0042034d b9ffffffff mov ecx,0FFFFFFFFh > 00420352 89df mov edi,ebx > 00420354 f2ae repne scas byte ptr es:[edi] > 00420356 f7d1 not ecx > 00420358 8d51ff lea edx,[ecx-1] > 0042035b b9ffffffff mov ecx,0FFFFFFFFh > 00420360 89f7 mov edi,esi > 00420362 f2ae repne scas byte ptr es:[edi] > 00420364 f7d1 not ecx > 00420366 49 dec ecx > 00420367 7466 je git_remote_curl+0x203cf (004203cf) > 00420369 85d2 test edx,edx > 0042036b 0f84b1000000 je git_remote_curl+0x20422 (00420422) > 00420371 89f7 mov edi,esi > 00420373 89de mov esi,ebx > ... > > So its the first parameter that is NULL. The second parameter is: > > 0:000> da poi(ebp+c) > 0046f98f "libexec/git-core" > > I don't know how to build msysGit so that symbols are generated so > I've attempted to reconstruct the source code; which ends up looking > something like the following: > > int some_unknown_func(char *arg1, char *arg2) > { > len1 = strlen(arg1) - 1; // <- crash here > len2 = strlen(arg2); > len3 = len2 - 1; > > if (len2 != 1) { > if (!len1) > return 0; > for (;;) { > x = arg1[len1 - 1]; > > if (x != '/' && x != '\\') { > --len1; > --len3; > if (arg1[len1] != arg2[len3]) > return 0; > } else { > ... > } > } > } > } > > Perhaps those more familiar with git's sources might recognise code > that looks similar to the above sequence. 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 ^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-13 10:53 ` Johannes Sixt @ 2009-10-13 11:43 ` Michael Wookey 2009-10-13 21:06 ` Junio C Hamano 0 siblings, 1 reply; 12+ messages in thread From: Michael Wookey @ 2009-10-13 11:43 UTC (permalink / raw) To: Johannes Sixt Cc: Junio C Hamano, eduard stefan, Tay Ray Chuan, Git Mailing List, msysgit 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 :) Tested-by: Michael Wookey <michaelwookey@gmail.com> ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Git 1.6.5-rc git clone unhandled exception using http protocol 2009-10-13 11:43 ` Michael Wookey @ 2009-10-13 21:06 ` Junio C Hamano 0 siblings, 0 replies; 12+ messages in thread From: Junio C Hamano @ 2009-10-13 21:06 UTC (permalink / raw) To: Michael Wookey Cc: Johannes Sixt, eduard stefan, Tay Ray Chuan, Git Mailing List, msysgit Michael Wookey <michaelwookey@gmail.com> writes: > 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! ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2009-10-13 21:07 UTC | newest] Thread overview: 12+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2009-10-09 17:27 Git 1.6.5-rc git clone unhandled exception using http protocol eduard stefan 2009-10-10 10:55 ` Tay Ray Chuan [not found] ` <4AD09F5E.9090304@gmail.com> [not found] ` <be6fef0d0910100811l325d3df1jdf8d3d9dd51e3385@mail.gmail.com> 2009-10-10 15:55 ` eduard stefan 2009-10-10 16:07 ` Tay Ray Chuan 2009-10-10 16:52 ` eduard stefan 2009-10-10 22:54 ` Tay Ray Chuan 2009-10-11 21:12 ` eduard stefan 2009-10-13 3:36 ` Git 1.6.5 " eduard stefan 2009-10-13 10:10 ` Git 1.6.5-rc " Michael Wookey 2009-10-13 10:53 ` Johannes Sixt 2009-10-13 11:43 ` Michael Wookey 2009-10-13 21:06 ` Junio C Hamano
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).