This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Attica - incorrect credential presence test ?

Tags: None
(comma "," separated)
User avatar
Turambar
Registered Member
Posts
2
Karma
0
OS
Hi

I have a little doubt about the hasCredentials() method in the QtPlatformDependent class of the Attica library.
I think that there's a logic mistake in it, but I'd like to discuss it with someone rather than commiting something I'm not a 100% sure about.

Now for the thing itself, it's actually quite straight. In qtplatformdependent.cpp at the line 51:

Code: Select all
bool QtPlatformDependent::hasCredentials(const QUrl& baseUrl) const
{
    return !m_passwords.contains(baseUrl.toString());
}


I think it's doing the opposite job, that the ! in the return shouldn't be there



Or am I mistaking somewhere?
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
I would recommend talking with fregl on #kde-devel on Freenode.
It looks wrong to me too...


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
frederik
Moderator
Posts
37
Karma
0
OS
Fixed. Thanks a lot!
Did you try to use Attica in it's Qt-only version? It has received almost no testing so far, so I'd be interested in hearing how far you got.
Cheers
Frederik
User avatar
Turambar
Registered Member
Posts
2
Karma
0
OS
Unless I've made a mistake along the road, no I shouldn't have been using Attica in it's Qt-only version. It's been used with Akonadi, using KDE 4.3 when the problem was noticed.

The source code is here if you're interested (however it's now using KDE 4.4, if that makes any difference)


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Sogou [Bot]