From: Linus Torvalds Date: Thu, 6 Mar 2008 02:25:10 +0000 (-0800) Subject: Add 'df_name_compare()' helper function X-Git-Tag: v1.5.5-rc0~25^2~11 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/0ab9e1e8cdaefdd33bf24bb0be0ec766483f8bbe?hp=0ab9e1e8cdaefdd33bf24bb0be0ec766483f8bbe Add 'df_name_compare()' helper function This new helper is identical to base_name_compare(), except it compares conflicting directory/file entries as equal in order to help handling DF conflicts (thus the name). Note that while a directory name compares as equal to a regular file with the new helper, they then individually compare _differently_ to a filename that has a dot after the basename (because '\0' < '.' < '/'). So a directory called "foo/" will compare equal to a file "foo", even though "foo.c" will compare after "foo" and before "foo/" This will be used by routines that want to traverse the git namespace but then handle conflicting entries together when possible. Signed-off-by: Linus Torvalds Signed-off-by: Junio C Hamano ---