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

Re: bug found (Re: git-fast-export SIGSEGV on solaris + backtrace)

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 3, 2008, 08:30 UTC
Message-ID
<7vk5g32wve.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<486C248E.4060205@gmail.com>
SungHyun Nam <goweol@gmail.com> writes:
Show 7 quoted lines
> And the code says it:
>         for (i = 0; i < idnums.size; ++i) {
>                 deco++;
>                 if (deco && deco->base && deco->base->type == 1) {
>
> The 'deco' should be post-incremented? or
> Checking code should be  (i < idnums.size - 1)?

The variable "deco" is a pointer that walks over a hashtable from its offset 0 to its end, so it can never be NULL (well, the code increments before it tests the variable for NULLness, so it is clear that the test is bogus).

What was I smoking when I applied df6a7ff (builtin-fast-export: Add importing and exporting of revision marks, 2008-06-11), I have to wonder...

Thanks for the fix.
Previous: SungHyun NamNext: Johannes Schindelin
Message 2 of 3 in “bug found (Re: git-fast-export SIGSEGV on solaris + backtrace)”
  1. SungHyun NamJul 3, 2008
  2. Junio C HamanoJul 3, 2008
  3. Johannes SchindelinJul 3, 2008

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.