rdma_dist: Set socket packet mode to 4.
Fix minor warnings.