From 556af6cfcbd866c1b47cb39209931310831d635c Mon Sep 17 00:00:00 2001 From: Marc Blank Date: Thu, 21 Jun 2012 09:50:30 -0700 Subject: [PATCH] Setup port from services.xml when autoconfiguring Change-Id: Iec2d3fddb345b57ba84a794d9e92cad7a631c105 --- .../com/android/email/activity/setup/AccountSetupBasics.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/email2/src/com/android/email/activity/setup/AccountSetupBasics.java b/email2/src/com/android/email/activity/setup/AccountSetupBasics.java index d6bb9d670..506c82706 100644 --- a/email2/src/com/android/email/activity/setup/AccountSetupBasics.java +++ b/email2/src/com/android/email/activity/setup/AccountSetupBasics.java @@ -454,6 +454,9 @@ public class AccountSetupBasics extends AccountSetupActivity HostAuth recvAuth = account.getOrCreateHostAuthRecv(this); HostAuth.setHostAuthFromString(recvAuth, mProvider.incomingUri); recvAuth.setLogin(mProvider.incomingUsername, password); + EmailServiceInfo info = EmailServiceUtils.getServiceInfo(this, recvAuth.mProtocol); + recvAuth.mPort = + ((recvAuth.mFlags & HostAuth.FLAG_SSL) != 0) ? info.portSsl : info.port; HostAuth sendAuth = account.getOrCreateHostAuthSend(this); HostAuth.setHostAuthFromString(sendAuth, mProvider.outgoingUri);