diff options
| author | Junio C Hamano <gitster@pobox.com> | 2014-07-22 10:59:36 -0700 | 
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2014-07-22 10:59:37 -0700 | 
| commit | 12621cb22224d1c2f507a643a578e386ee891c5c (patch) | |
| tree | d0ab888b37baa09db9c7ef74840b739ff3cafb09 /commit.c | |
| parent | 4328190a81ea5aef679774322c7f9faf06b453af (diff) | |
| parent | 1cefa143250ad8c60e2a3db6c18278f7bed508f5 (diff) | |
| download | git-12621cb22224d1c2f507a643a578e386ee891c5c.tar.gz | |
Merge branch 'rs/code-cleaning'
* rs/code-cleaning:
  remote-testsvn: use internal argv_array of struct child_process in cmd_import()
  bundle: use internal argv_array of struct child_process in create_bundle()
  fast-import: use hashcmp() for SHA1 hash comparison
  transport: simplify fetch_objs_via_rsync() using argv_array
  run-command: use internal argv_array of struct child_process in run_hook_ve()
  use commit_list_count() to count the members of commit_lists
  strbuf: use strbuf_addstr() for adding C strings
Diffstat (limited to 'commit.c')
| -rw-r--r-- | commit.c | 7 | 
1 files changed, 1 insertions, 6 deletions
| @@ -970,12 +970,7 @@ struct commit_list *get_merge_bases_many(struct commit *one,  	}  	/* There are more than one */ -	cnt = 0; -	list = result; -	while (list) { -		list = list->next; -		cnt++; -	} +	cnt = commit_list_count(result);  	rslt = xcalloc(cnt, sizeof(*rslt));  	for (list = result, i = 0; list; list = list->next)  		rslt[i++] = list->item; | 
