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

Re: [PATCH] Fix segfault for insane ident line

From
Jiang Xin <worldhello.net@gmail.com>
Date
Apr 25, 2013, 10:52 UTC
Message-ID
<CANYiYbGC0VqtsPH8H4wmarJC-Y480+zE7irf1Y1RNLR2jA=EjA@mail.gmail.com>
In-Reply-To
<e7453e2b99517ebed045d82be4d5f2c9388bb002.1366885748.git.worldhello.net@gmail.com>

Oops, Ignore this patch please, I found they were already fixed by the following commits of next branch. Maybe next time I should patch something in next branch.

commit 9dbe7c3d7f4424cf0c27c2d4efabf72e58fa76b9
Author: René Scharfe <rene.scharfe@lsrfire.ath.cx>
Date:   Wed Apr 17 20:33:35 2013 +0200
    pretty: handle broken commit headers gracefully
    Centralize the parsing of the date and time zone strings in the new
    helper function show_ident_date() and make sure it checks the pointers
    provided by split_ident_line() for NULL before use.
    Reported-by: Ivan Lyapunov <dront78@gmail.com>
    Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
commit de5abe9fe91a496d019d62abefe23df9d72fad30
Author: René Scharfe <rene.scharfe@lsrfire.ath.cx>
Date:   Wed Apr 17 20:33:54 2013 +0200
    blame: handle broken commit headers gracefully
    split_ident_line() can leave us with the pointers date_begin, date_end,
    tz_begin and tz_end all set to NULL.  Check them before use and supply
    the same fallback values as in the case of a negative return code from
    split_ident_line().
    The "(unknown)" is not actually shown in the output, though, because it
    will be converted to a number (zero) eventually.
    Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>

-- 蒋鑫

北京群英汇信息技术有限公司 邮件: worldhello.net@gmail.com 网址: http://www.ossxp.com/ 博客: http://www.worldhello.net/ 微博: http://weibo.com/gotgit/ 电话: 18601196889

Previous: Jiang Xin
Message 3 of 3 in “Fix segfault for insane ident line”
  1. Fix segfault for insane ident lineJiang Xin, Apr 25, 2013
  2. Fix segfault for insane ident lineJiang Xin, Apr 25, 2013
  3. Jiang XinApr 25, 2013

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.