After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 738906 - smartcard: fix lock confusion in gsd_smartcard_manager_get_login_token
smartcard: fix lock confusion in gsd_smartcard_manager_get_login_token
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: smartcard
unspecified
Other All
: Normal normal
: ---
Assigned To: Ray Strode [halfline]
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2014-10-20 23:18 UTC by Ray Strode [halfline]
Modified: 2014-10-20 23:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
smartcard: fix lock confusion in gsd_smartcard_manager_get_login_token (3.56 KB, patch)
2014-10-20 23:18 UTC, Ray Strode [halfline]
committed Details | Review

Description Ray Strode [halfline] 2014-10-20 23:18:04 UTC
gsd_smartcard_manager_get_login_token will return as soon as it finds
a login token. In doing so, it neglects to drop the lock it took before
its search began.

This commit drops the early return from the code so that the found
and not found cases follow the same exit path, where the lock is
properly dropped.
Comment 1 Ray Strode [halfline] 2014-10-20 23:18:06 UTC
Created attachment 288995 [details] [review]
smartcard: fix lock confusion in gsd_smartcard_manager_get_login_token
Comment 2 Ray Strode [halfline] 2014-10-20 23:20:45 UTC
(pushing since I don't expect to get review on smartcard stuff, but if someone has comments let me know and I can do follow up changes)

Attachment 288995 [details] pushed as e1aac8d - smartcard: fix lock confusion in gsd_smartcard_manager_get_login_token