Has anyone found a good way to test an image file?

I've had problems in the past where images generate internal segmentation
faults during downloads. I've usually been able to correct the source
machine and re-upload my image to fix the problem.

Is there a way to test the image file to see if it is good? Is there a
way to download it to a NULL device or ???

Any ideas would be helpfull.