btrfs-progs: save and return error number correctly in check_chunks_and_extents