builtin/receive-pack: convert one use of EMPTY_TREE_SHA1_HEX
Convert one use of EMPTY_TREE_SHA1_HEX to use empty_tree_oid_hex to avoid a dependency on a given hash algorithm. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
brian m. carlson committed
May 2, 2018 at 00:26 UTC
c00866a2cc94dd0db3306963fad38b5711e542a2
1 file changed
+1
-1
builtin/receive-pack.c
+1
-1
@@ -968,7 +968,7 @@ static const char *push_to_deploy(unsigned char *sha1,
968
return "Working directory has unstaged changes";
969
970
/* diff-index with either HEAD or an empty tree */
971
- diff_index[4] = head_has_history() ? "HEAD" : EMPTY_TREE_SHA1_HEX;
971
+ diff_index[4] = head_has_history() ? "HEAD" : empty_tree_oid_hex();
972
973
child_process_init(&child);
974
child.argv = diff_index;