Re: [PATCH v2 05/14] sha1_file: convert hash_sha1_file to object_id

2018-01-22 Thread Duy Nguyen
On Mon, Jan 22, 2018 at 7:44 PM, Patryk Obara wrote: > On 22 January 2018 at 12:49, Duy Nguyen wrote: >> On Mon, Jan 22, 2018 at 12:04:28PM +0100, Patryk Obara wrote: >>> @@ -969,7 +969,7 @@ static int ident_to_worktree(const char *path, const >>> char *src, size_t len, >>> >>> /*

Re: [PATCH v2 05/14] sha1_file: convert hash_sha1_file to object_id

2018-01-22 Thread Patryk Obara
On 22 January 2018 at 12:49, Duy Nguyen wrote: > On Mon, Jan 22, 2018 at 12:04:28PM +0100, Patryk Obara wrote: >> @@ -969,7 +969,7 @@ static int ident_to_worktree(const char *path, const >> char *src, size_t len, >> >> /* step 4: substitute */ >> strbuf_addstr(buf, "Id

Re: [PATCH v2 05/14] sha1_file: convert hash_sha1_file to object_id

2018-01-22 Thread Duy Nguyen
On Mon, Jan 22, 2018 at 12:04:28PM +0100, Patryk Obara wrote: > @@ -969,7 +969,7 @@ static int ident_to_worktree(const char *path, const char > *src, size_t len, > > /* step 4: substitute */ > strbuf_addstr(buf, "Id: "); > - strbuf_add(buf, sha1_to_hex(sha

[PATCH v2 05/14] sha1_file: convert hash_sha1_file to object_id

2018-01-22 Thread Patryk Obara
Convert the declaration and definition of hash_sha1_file to use struct object_id and adjust all function calls. Rename this function to hash_object_file. Signed-off-by: Patryk Obara --- apply.c | 4 ++-- builtin/index-pack.c | 5 ++--- builtin/replace.c| 2 +- bu