From: Michael Haggerty Date: Wed, 1 Oct 2014 10:28:36 +0000 (+0200) Subject: commit_lock_file_to(): refactor a helper out of commit_lock_file() X-Git-Tag: v2.2.0-rc0~53^2~6 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/751bacedaa507b7b6d10b2c1f48e019a01a8fa6e?ds=inline;hp=751bacedaa507b7b6d10b2c1f48e019a01a8fa6e commit_lock_file_to(): refactor a helper out of commit_lock_file() commit_locked_index(), when writing to an alternate index file, duplicates (poorly) the code in commit_lock_file(). And anyway, it shouldn't have to know so much about the internal workings of lockfile objects. So extract a new function commit_lock_file_to() that does the work common to the two functions, and call it from both commit_lock_file() and commit_locked_index(). Signed-off-by: Michael Haggerty Signed-off-by: Junio C Hamano ---