-rw-r--r-- | noncore/net/mail/libmailwrapper/nntpwrapper.cpp | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/noncore/net/mail/libmailwrapper/nntpwrapper.cpp b/noncore/net/mail/libmailwrapper/nntpwrapper.cpp index c68964d..54e0ed4 100644 --- a/noncore/net/mail/libmailwrapper/nntpwrapper.cpp +++ b/noncore/net/mail/libmailwrapper/nntpwrapper.cpp | |||
@@ -119,2 +119,3 @@ void NNTPwrapper::login() | |||
119 | const char *server, *user, *pass; | 119 | const char *server, *user, *pass; |
120 | QString User,Pass; | ||
120 | uint16_t port; | 121 | uint16_t port; |
@@ -125,2 +126,4 @@ void NNTPwrapper::login() | |||
125 | 126 | ||
127 | user = pass = 0; | ||
128 | |||
126 | if ( account->getUser().isEmpty() || account->getPassword().isEmpty() ) { | 129 | if ( account->getUser().isEmpty() || account->getPassword().isEmpty() ) { |
@@ -130,4 +133,4 @@ void NNTPwrapper::login() | |||
130 | // ok | 133 | // ok |
131 | user = login.getUser().latin1(); | 134 | User = login.getUser().latin1(); |
132 | pass = login.getPassword().latin1(); | 135 | Pass = login.getPassword().latin1(); |
133 | } else { | 136 | } else { |
@@ -138,6 +141,13 @@ void NNTPwrapper::login() | |||
138 | } else { | 141 | } else { |
139 | user = account->getUser().latin1(); | 142 | User = account->getUser().latin1(); |
140 | pass = account->getPassword().latin1(); | 143 | Pass = account->getPassword().latin1(); |
141 | } | 144 | } |
142 | 145 | ||
146 | if (User.isEmpty()) { | ||
147 | user=0; | ||
148 | pass = 0; | ||
149 | } else { | ||
150 | user=User.latin1(); | ||
151 | pass=Pass.latin1(); | ||
152 | } | ||
143 | // bool ssl = account->getSSL(); | 153 | // bool ssl = account->getSSL(); |
@@ -158,3 +168,3 @@ void NNTPwrapper::login() | |||
158 | 168 | ||
159 | nntp_mailstorage_init(m_nntp,(char*)server, port, NULL, conntype, NNTP_AUTH_TYPE_PLAIN, | 169 | nntp_mailstorage_init(m_nntp,(char*)server, port, NULL, CONNECTION_TYPE_PLAIN, NNTP_AUTH_TYPE_PLAIN, |
160 | (char*)user,(char*)pass,0,0,0); | 170 | (char*)user,(char*)pass,0,0,0); |