Added msg recv primitives in peer code