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

Re: [RFC] get_pathspec(): free() old buffer if rewriting

From
Junio C Hamano <junkio@cox.net>
Date
May 7, 2006, 04:50 UTC
Message-ID
<7vejz6phei.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<7viroipijf.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <junkio@cox.net> writes:
Show 12 quoted lines
> int match_pathspec(const char *path, int len,
> 	           struct pathspec **pathspec);
>
> 	See if the path (with length) matches the given spec.
> 	path[len-1] == '/' signals that the caller is traversing
> 	a tree and checking if it is worth descending into the
> 	tree.
> ...
> and when traversing the tree for A and B, upon seeing "Documentation"
> entry in the topleve tree object buffers, call:
>
> 	path_match("Documentation", 14, 1, spec)

Oops, match_pathspec("Documentation/", 15, spec) is what I meant here. Likewise in the later examples.

Previous: Junio C Hamano
Message 5 of 5 in “[RFC] get_pathspec(): free() old buffer if rewriting”
  1. Johannes SchindelinMay 6, 2006
  2. Linus TorvaldsMay 6, 2006
  3. Johannes SchindelinMay 6, 2006
  4. Junio C HamanoMay 7, 2006
  5. Junio C HamanoMay 7, 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.