]> git.ipfire.org Git - thirdparty/git.git/commit - refs.c
search_ref_dir(): return an index rather than a pointer
authorMichael Haggerty <mhagger@alum.mit.edu>
Mon, 22 Apr 2013 19:52:26 +0000 (21:52 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 1 May 2013 22:33:10 +0000 (15:33 -0700)
commit9fc0a64806aa72ca7ef1c20468ffcef5c86978b8
tree7c587ee7922b35982c9cf5a810d0851ad0dd61fc
parentab292bc4f30dd29d3d111b040b9e982f20b9ceb7
search_ref_dir(): return an index rather than a pointer

Change search_ref_dir() to return the index of the sought entry (or -1
on error) rather than a pointer to the entry.  This will make it more
natural to use the function for removing an entry from the list.

Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c