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

Re: [PATCH] sha1_name: reorganize get_sha1_basic()

From
Ramkumar Ramachandra <artagnon@gmail.com>
Date
May 2, 2013, 09:40 UTC
Message-ID
<CALkWK0=qknGMuHN-zJzLXDNRLFdaBssccnkXbXbM8SZ+ORKiZA@mail.gmail.com>
In-Reply-To
<1367455791-30091-1-git-send-email-felipe.contreras@gmail.com>
Felipe Contreras wrote:
Show 7 quoted lines
> @@ -447,6 +449,9 @@ static int get_sha1_basic(const char *str, int len, unsigned char *sha1)
>         if (len && str[len-1] == '}') {
>                 for (at = len-2; at >= 0; at--) {
>                         if (str[at] == '@' && str[at+1] == '{') {
> +                               if (at == 0 && str[2] == '-')
> +                                       /* @{-N} syntax */
> +                                       continue;
Nicely done.  Thanks.
Previous: Felipe ContrerasNext: Duy Nguyen
Message 4 of 6 in “sha1_name: reorganize get_sha1_basic()”
  1. sha1_name: reorganize get_sha1_basic()Felipe Contreras, May 2, 2013
  2. Felipe ContrerasMay 2, 2013
  3. Felipe ContrerasMay 2, 2013
  4. Ramkumar RamachandraMay 2, 2013
  5. Duy NguyenMay 2, 2013
  6. Felipe ContrerasMay 2, 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.