D29170: Detect executables without +x permission in $PATH to improve error message
    David Faure 
    noreply at phabricator.kde.org
       
    Sat Apr 25 10:53:19 BST 2020
    
    
  
dfaure created this revision.
dfaure added a reviewer: ahmadsamir.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
dfaure requested review of this revision.
REVISION SUMMARY
  QStandardPaths::findExecutable will not return to us a non-executable binary.
  So implement our own iteration over $PATH to detect such a case.
  Note: this doesn't handle the case where PATH isn't set at all (QStandardPaths implements a fallback)
  nor do we implement this for Windows (where chmod -x doesn't really exist as is). I think this is fine,
  in the worst case the user will get the other error message, program not found.
TEST PLAN
  'sudo chmod a-x /usr/bin/gwenview' then try opening a picture with gwenview from e.g. dolphin, see the error message
  
  CCBUG: 415567
REPOSITORY
  R241 KIO
BRANCH
  2020_04_findExecutable
REVISION DETAIL
  https://phabricator.kde.org/D29170
AFFECTED FILES
  src/gui/kprocessrunner.cpp
To: dfaure, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20200425/a49adfcf/attachment-0001.html>
    
    
More information about the Kde-frameworks-devel
mailing list