Validate compressed audio formats.
Fix null checks in afGetSampleFormat() and afGetVirtualSampleFormat().

Thanks to David Lassonde for pointing out this problem.
Fix conversion specifications in error messages.
Use C++11 override keyword with compilers that support it.
Include <unistd.h> to provide declaration of close().
Set compression type before initializing sample format.
Remove unnecessary check for positive channel count.

This check is already performed in afInitChannels().
Add test for opening a NeXT sound file with zero channels.
Report error when attempting to open a file with zero channels.
Report error when attempting to open a file with invalid sample width.