正在显示
2 个修改的文件
包含
3 行增加
和
3 行删除
@@ -42,9 +42,9 @@ func (a *loginAuth) Next(fromServer []byte, more bool) ([]byte, error) { | @@ -42,9 +42,9 @@ func (a *loginAuth) Next(fromServer []byte, more bool) ([]byte, error) { | ||
42 | } | 42 | } |
43 | 43 | ||
44 | switch { | 44 | switch { |
45 | - case bytes.Equal(fromServer, []byte("username:")): | 45 | + case bytes.EqualFold(fromServer, []byte("Username:")): |
46 | return []byte(a.username), nil | 46 | return []byte(a.username), nil |
47 | - case bytes.Equal(fromServer, []byte("Password:")): | 47 | + case bytes.EqualFold(fromServer, []byte("Password:")): |
48 | return []byte(a.password), nil | 48 | return []byte(a.password), nil |
49 | default: | 49 | default: |
50 | return nil, fmt.Errorf("mail: unexpected server challenge: %s", fromServer) | 50 | return nil, fmt.Errorf("mail: unexpected server challenge: %s", fromServer) |
-
请 注册 或 登录 后发表评论