src/io/ioutils.h: add functions to check samplerate and channels, use in sink_*.c