reset.c: inline update_index_refresh()

Now that there is only one caller left to the single-line method update_index_refresh(), inline it. Signed-off-by: Martin von Zweigbergk <martinvonz@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Martin von Zweigbergk committed Jan 14, 2013 at 21:47 UTC 7637df131ec9939b737ca284874478cb5c899348
1 file changed +5 -9
builtin/reset.c
+5 -9
@@ -109,12 +109,6 @@ static void print_new_head_line(struct commit *commit)
109 printf("\n");
110 }
111
112 -static void update_index_refresh(int flags)
113 -{
114 - refresh_index(&the_index, (flags), NULL, NULL,
115 - _("Unstaged changes after reset:"));
116 -}
117 -
112 static void update_index_from_diff(struct diff_queue_struct *q,
113 struct diff_options *opt, void *data)
114 {
@@ -329,9 +323,11 @@ int cmd_reset(int argc, const char **argv, const char *prefix)
323 die(_("Could not reset index file to revision '%s'."), rev);
324 }
325
332 - if (reset_type == MIXED) /* Report what has not been updated. */
333 - update_index_refresh(
334 - quiet ? REFRESH_QUIET : REFRESH_IN_PORCELAIN);
326 + if (reset_type == MIXED) { /* Report what has not been updated. */
327 + int flags = quiet ? REFRESH_QUIET : REFRESH_IN_PORCELAIN;
328 + refresh_index(&the_index, flags, NULL, NULL,
329 + _("Unstaged changes after reset:"));
330 + }
331
332 if (write_cache(newfd, active_cache, active_nr) ||
333 commit_locked_index(lock))