more robust cpio checking