Minor changes to work in remote connection.