073bd89262
There is a constraint on the length of the name in a reference, so WithName should be checking this instead of potentially creating a reference that doesn't comply with the rules. Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>