fix ReceiveMessage to return None if conn is closed