receiver.v: fixed many bugs