Review Request: Extend KStandardDirs::find[All]Exe() to also look for .com, and .bat on Windows

Thomas Friedrichsmeier thomas.friedrichsmeier at ruhr-uni-bochum.de
Tue Apr 6 16:53:21 BST 2010


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/3388/
-----------------------------------------------------------

(Updated 2010-04-06 15:53:21.359159)


Review request for kdelibs, Jaroslaw Staniek and Patrick Spendrin.


Changes
-------

Thanks for that info. The updated version of the patch makes use of the PATHEXT environment variable as suggested (falling back to .com;.exe;.bat if that is not available).


Summary
-------

On Windows, KStandardDirs::findExe(), and findAllExe() append ".exe" to the filename to look for. However, executable files on Windows may also end in .com or .bat. Therefore, this patch looks for all three extensions in the order .exe, .com, .bat.

For example, rkward ships with a wrapper script rkward.bat. kwinstartmenu relies on KStandardDirs::findExe() to locate the executables referenced in .desktop files, and fails to find rkward.bat. This patch fixes that.


P.S.: Where should windows-specific review requests go to?


Diffs (updated)
-----

  trunk/KDE/kdelibs/kdecore//kernel/kstandarddirs.cpp 1106410 

Diff: http://reviewboard.kde.org/r/3388/diff


Testing
-------

Non-systematic. kwinstartmenu now adds rkward as expected. All other apps are added as before.

Ironically, the unittests all fail for me due to failure to find the test executables (also without this patch!), so I cannot run them, ATM.


Thanks,

Thomas





More information about the kde-core-devel mailing list