Re: [PATCH v9 2/5] worktree: refactor find_linked_symref function

2015-10-02 Thread Junio C Hamano
Michael Rappazzo writes: > +static int parse_ref(char *path_to_ref, struct strbuf *ref, int *is_detached) > +{ > + if (is_detached) > + *is_detached = 0; > + if (!strbuf_readlink(ref, path_to_ref, 0)) > + if (!starts_with(ref->buf, "refs/") || > +

[PATCH v9 2/5] worktree: refactor find_linked_symref function

2015-10-02 Thread Michael Rappazzo
Refactoring will help transition this code to provide additional useful worktree functions. Signed-off-by: Michael Rappazzo --- worktree.c | 94 -- 1 file changed, 67 insertions(+), 27 deletions(-) diff --git a/worktree.c b/worktree.c