Re: [PATCH v5 02/12] sha1-file: provide functions to look up hash algorithms
- From
Derrick Stolee <stolee@gmail.com>
- Date
- Nov 13, 2018, 18:42 UTC
- Message-ID
- <06e5bc95-b901-163a-5088-888878187ca2@gmail.com>
- In-Reply-To
- <20181104234458.139223-3-sandals@crustytoothpaste.net>
On 11/4/2018 6:44 PM, brian m. carlson wrote:
Show 11 quoted lines
> +int hash_algo_by_name(const char *name)
> +{
> + int i;
> + if (!name)
> + return GIT_HASH_UNKNOWN;
> + for (i = 1; i < GIT_HASH_NALGOS; i++)
> + if (!strcmp(name, hash_algos[i].name))
> + return i;
> + return GIT_HASH_UNKNOWN;
> +}
> +Today's test coverage report [1] shows this method is not covered in the test suite. Looking at 'pu', it doesn't have any callers.
Do you have a work in progress series that will use this? Could we add a test-tool to exercise this somehow?
Thanks, -Stolee
[1] https://public-inbox.org/git/97be3e21-6a8c-9718-5161-37318f6d685f@gmail.com/