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

Re: [PATCH v2] ls-files: adding support for submodules

From
BWBrandon Williams <bmwill@google.com>
Date
Sep 13, 2016, 03:35 UTC
Message-ID
<CAKoko1pc7bB85cjho7mg0mDQrDjmfvpAVC8FS=VtQ+Dwk6eCYA@mail.gmail.com>
In-Reply-To
<1473726835-143289-1-git-send-email-bmwill@google.com>
Show 11 quoted lines
>  static void write_name(const char *name)
>  {
>         /*
> +        * NEEDSWORK: To make this thread-safe, full_name would have to be owned
> +        * by the caller.
> +        *
> +        * full_name get reused across output lines to minimize the allocation
> +        * churn.
> +        */
> +       static struct strbuf full_name = STRBUF_INIT;
> +       if (output_path_prefix != '\0') {
It was pointed out to me that this should be:
    if (*output_path_prefix != '\0') {
Show 5 quoted lines
> +               strbuf_reset(&full_name);
> +               strbuf_addstr(&full_name, output_path_prefix);
> +               strbuf_addstr(&full_name, name);
> +               name = full_name.buf;
> +       }
Previous: Brandon WilliamsNext: Junio C Hamano
Message 12 of 22 in “ls-files: adding support for submodules”
  1. ls-files: adding support for submodulesBrandon Williams, Sep 9, 2016
  2. Jeff KingSep 9, 2016
  3. Junio C HamanoSep 9, 2016
  4. Junio C HamanoSep 9, 2016
  5. Stefan BellerSep 9, 2016
  6. Junio C HamanoSep 11, 2016
  7. Jeff KingSep 12, 2016
  8. Jeff KingSep 12, 2016
  9. Junio C HamanoSep 12, 2016
  10. Junio C HamanoSep 12, 2016
  11. ls-files: adding support for submodulesBrandon Williams, Sep 13, 2016
  12. Brandon WilliamsSep 13, 2016
  13. Junio C HamanoSep 13, 2016
  14. Junio C HamanoSep 15, 2016
  15. Junio C HamanoSep 15, 2016
  16. Junio C HamanoSep 15, 2016
  17. Junio C HamanoSep 15, 2016
  18. 2/2 SQUASH??? UndecidedJunio C Hamano, Sep 15, 2016
  19. Stefan BellerSep 15, 2016
  20. Brandon WilliamsSep 15, 2016
  21. 1/2 SQUASH???Junio C Hamano, Sep 15, 2016
  22. Brandon WilliamsSep 12, 2016

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.