Respect hardlinks during flatsize calculation.

Issue:	#812
Reported by:	@gelraen