copy from pack_b