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

Re: [PATCH] git-mv: Fix error with multiple sources.

From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
Date
Jan 22, 2010, 07:03 UTC
Message-ID
<vpq7hrapqng.fsf@bauges.imag.fr>
In-Reply-To
<718290.769818367-sendEmail@darysmbp>
"David Rydh" <dary@math.berkeley.edu> writes:
Show 6 quoted lines
>  		if (!is_absolute_path(given_config_file) && prefix)
> -			config_exclusive_filename = prefix_filename(prefix,
> +			config_exclusive_filename = xstrdup(prefix_filename(prefix,
>  								    strlen(prefix),
> -								    argv[2]);
> +									argv[2]));
Broken indentation on the last two lines.

Other than that, you use strdup without free-ing the result. Probably not so serious, but it may be cleaner to actually call free, or to explain why you don't (in commit message).

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
Previous: Junio C HamanoNext: Johannes Sixt
Message 7 of 10 in “git-mv: Fix error with multiple sources.”
  1. git-mv: Fix error with multiple sources.David Rydh, Jan 21, 2010
  2. Junio C HamanoJan 22, 2010
  3. David RydhJan 22, 2010
  4. Junio C HamanoJan 22, 2010
  5. David RydhJan 22, 2010
  6. Junio C HamanoJan 22, 2010
  7. Matthieu MoyJan 22, 2010
  8. Johannes SixtJan 22, 2010
  9. David RydhJan 22, 2010
  10. Johannes SixtJan 22, 2010

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.