tarsum: correct close and finish reads

Tarsum now correctly closes the internal TarWriter which appends
a block of 1024 zeros to the end of the returned archive.

~~Also a small refactor of the Read() method to use fewer levels of indentation; move initialization out to separate method.~~

fixes #5055
fixes https://github.com/docker/docker-registry/issues/310

Signed-off-by: Josh Hawn <josh.hawn@docker.com>