diff options
| author | Junio C Hamano <gitster@pobox.com> | 2015-12-11 11:14:12 -0800 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2015-12-11 11:14:13 -0800 |
| commit | 0af22d6fffe5169f641fb9815468ae97e47cd73f (patch) | |
| tree | e61f2ffb0f66e0d8c5892c0795b6f8a521e4f2c9 /remote.c | |
| parent | 8c0a546670a2cb2349c5baedbf4b87268e52c665 (diff) | |
| parent | e510ab898865fdaf131e9bc9fd6ab6b7c4a94c9b (diff) | |
| download | git-0af22d6fffe5169f641fb9815468ae97e47cd73f.tar.gz | |
Merge branch 'rs/pop-commit' into maint
Code simplification.
* rs/pop-commit:
use pop_commit() for consuming the first entry of a struct commit_list
Diffstat (limited to 'remote.c')
| -rw-r--r-- | remote.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -1975,10 +1975,8 @@ int resolve_remote_symref(struct ref *ref, struct ref *list) static void unmark_and_free(struct commit_list *list, unsigned int mark) { while (list) { - struct commit_list *temp = list; - temp->item->object.flags &= ~mark; - list = temp->next; - free(temp); + struct commit *commit = pop_commit(&list); + commit->object.flags &= ~mark; } } |
