Sanitize master output

Replace any inf/nan in master output with zero, to prevent corrupted files/audio.