mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-23 18:02:15 -05:00
Issue 6280 -- SMTP Setup: ArrayIndexOutOfBoundsException: length=0; index=0
When the outgoing server settings don't require authentication, userInfoParts.length == 0.
This commit is contained in:
parent
95f62785fc
commit
bd4b7d3664
@ -95,7 +95,9 @@ public class SmtpTransport extends Transport {
|
||||
if (smtpUri.getUserInfo() != null) {
|
||||
try {
|
||||
String[] userInfoParts = smtpUri.getUserInfo().split(":");
|
||||
if (userInfoParts.length > 0) {
|
||||
username = URLDecoder.decode(userInfoParts[0], "UTF-8");
|
||||
}
|
||||
if (userInfoParts.length > 1) {
|
||||
password = URLDecoder.decode(userInfoParts[1], "UTF-8");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user