From: Karsten Blees Date: Thu, 14 Nov 2013 19:24:08 +0000 (+0100) Subject: builtin/update-index.c: cleanup update_one X-Git-Tag: v2.0.0-rc0~166^2~5 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/6bb69077b74b792ddef66e372c86e66dea8e449b?hp=6bb69077b74b792ddef66e372c86e66dea8e449b builtin/update-index.c: cleanup update_one do_reupdate calls update_one with a cache_entry.name, there's no need for the extra sanitation / normalization that happens in prefix_path. cmd_update_index calls update_one with an already prefixed path, no need to prefix_path twice. Remove the extra prefix_path from update_one. Also remove the now unused 'prefix' and 'prefix_length' parameters. As of d089eba "setup: sanitize absolute and funny paths in get_pathspec()", prefix_path uncoditionally returns a copy, even if the passed in path isn't changed. Lets unconditionally free() the result. Signed-off-by: Karsten Blees Signed-off-by: Junio C Hamano ---