distribution/digest
Stephen J Day 95bee1895a digest: panic on unavailable hash algorithm
After running into a few nil pointer errors during development, it is clear
that having this function return nil when a hash is not available is the wrong
approach. Nearly every time, this lack of availability was due to a missing
import statement for the hash. This is always a programming error.

To avoid future confusion, we now appropriately panic when the hash function is
not imported by the application. More dynamic uses of the package should call
Algorithm.Available() before calling Algorithm.Hash() to avoid this panic.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-12-29 15:24:32 -08:00
..
digest.go Remove tarsum support for digest package 2015-12-15 17:22:18 -08:00
digest_test.go Remove tarsum support for digest package 2015-12-15 17:22:18 -08:00
digester.go digest: panic on unavailable hash algorithm 2015-12-29 15:24:32 -08:00
digester_resumable_test.go Refactor specification of supported digests 2015-05-22 18:08:23 -07:00
doc.go Remove tarsum support for digest package 2015-12-15 17:22:18 -08:00
set.go Add remove and list functions to digest set 2015-09-29 10:04:15 -07:00
set_test.go Validate digest length on parsing 2015-12-02 16:04:06 -08:00
verifiers.go Remove tarsum support for digest package 2015-12-15 17:22:18 -08:00
verifiers_test.go Remove tarsum support for digest package 2015-12-15 17:22:18 -08:00