Skip to content
  • Harald Sitter's avatar
    improve error reporting for when kpasswdserver is unreachable · 5a870554
    Harald Sitter authored
    Summary:
    previously we'd not forward the errors coming out of the password dialog
    helper and instead eventually end up on generic access denied errors.
    seeing as the access denied is likely because we couldn't query auth info
    that is fairly misleading.
    
    checkPassword is now returning an error code instead of a bool. when we
    actually consider checkPassword an error we'll now raise this error
    instead of the generic access denied errors. when the user canceled
    the query we'll continue to raise the more topical error from smb (e.g.
    "access denied")
    
    primarily these errors appear when kiod/kpasswdserver is defunct
    or not installed meaning query functionality will not work at all.
    
    Test Plan:
    # broken kiod
    
    - remove dbus service file
    - kill
    - dolphin smb://host
    - no auth query
    - error about broken dialog
    
    # cancel
    
    - repair kiod
    - dolphin smb://host
    - auth query
    - cancel
    - auth query
    - cancel
    - error about access denied (because refused to authenticate)
    
    Reviewers: #frameworks, dfaure
    
    Reviewed By: dfaure
    
    Subscribers: ngraham, kde-frameworks-devel, kfm-devel
    
    Tags: #dolphin, #frameworks
    
    Differential Revision: https://phabricator.kde.org/D24387
    5a870554