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

Re: 1.3.2 git-clone segfaults

From
PRPavel Roskin <proski@gnu.org>
Date
May 17, 2006, 23:52 UTC
Message-ID
<1147909920.32050.29.camel@dv>
In-Reply-To
<1147894165.16654.10.camel@dv>
On Wed, 2006-05-17 at 15:29 -0400, Pavel Roskin wrote:
Show 10 quoted lines
> On Wed, 2006-05-17 at 13:32 -0500, Bill Yoder wrote:
> > /usr/local/downloads/git-1.3.2/git-clone: line 323: 25972  
> > Segmentation fault      git-http-fetch -v -a -w "$tname" "$name" "$1/"
> 
> I've seen git-http-fetch segfaults many times when cloning qgit, but
> it's hard to reproduce on demand.
> 
> I think you should compile git without optimizations and allow coredumps
> (ulimit -c  unlimited), then load git-http-fetch in gdb with the core
> (gdb --core=core git-http-fetch) and run bt to see the backtrace.

Also comment out both "trap" invocations in git-clone, or the coredump will be deleted.

That's what I've got on Fedora Core 5 x86_64 with glibc and curl debug info installed:

#0  __strncasecmp (s1=Variable "s1" is not available.
) at strncase.c:68
68        while ((result = TOLOWER (*p1) - TOLOWER (*p2++)) == 0)
(gdb) where
#0  __strncasecmp (s1=Variable "s1" is not available.
) at strncase.c:68
#1  0x00000031f3e26c09 in curl_strnequal (first=Variable "first" is not available.
) at strequal.c:60
#2  0x00000031f3e0f43a in checkheaders (data=Variable "data" is not available.
) at http.c:119
#3  0x00000031f3e10cf9 in Curl_http (conn=0x1c421c0, done=Variable "done" is not available.
) at http.c:1580
#4  0x00000031f3e1a858 in Curl_do (connp=0x83af88, done=0x7fff29c97ebb "\001\001")
    at url.c:3841
#5  0x00000031f3e28f22 in curl_multi_perform (multi_handle=0x53b590, 
    running_handles=0x7fff29c97ef8) at multi.c:526
#6  0x00000000004040c0 in step_active_slots () at http.c:376
#7  0x000000000040412c in run_active_slot (slot=0x546690) at http.c:400
#8  0x0000000000403e44 in http_cleanup () at http.c:275
#9  0x00000000004077d7 in main (argc=7, argv=0x7fff29c98258) at http-fetch.c:1274
(gdb) p p1
$1 = (const unsigned char *) 0x0
(gdb) p p2
$2 = (const unsigned char *) 0x31f3e2e817 "User-Agent:"
(gdb)
Looks like a curl bug to me.  curl 7.15.1, glibc 2.4, git master branch.
-- 
Regards,
Pavel Roskin
Previous: Pavel RoskinNext: Linus Torvalds
Message 6 of 7 in “1.3.2 git-clone segfaults”
  1. Bill YoderMay 17, 2006
  2. Fernando J. PeredaMay 17, 2006
  3. Junio C HamanoMay 17, 2006
  4. Bill YoderMay 17, 2006
  5. Pavel RoskinMay 17, 2006
  6. Pavel RoskinMay 17, 2006
  7. Linus TorvaldsMay 18, 2006

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.