mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 08:21:25 +00:00
Don't count '.exe' as part of program name on mswindows
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@24778 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
a4456d31b3
commit
24b2d3538f
2 changed files with 16 additions and 1 deletions
|
@ -712,7 +712,17 @@ static BOOL setSharedDefaults = NO; /* Flag to prevent infinite recursion */
|
|||
*/
|
||||
if (processName == nil)
|
||||
{
|
||||
processName = RETAIN([[NSProcessInfo processInfo] processName]);
|
||||
NSString *s = [[NSProcessInfo processInfo] processName];
|
||||
|
||||
#if defined(__MINGW32__)
|
||||
NSString *e = [s pathExtension];
|
||||
|
||||
if (e != nil && [e caseInsensitiveCompare: @"EXE"] == NSOrderedSame)
|
||||
{
|
||||
s = [s stringByDeletingPathExtension];
|
||||
}
|
||||
#endif
|
||||
processName = [s copy];
|
||||
}
|
||||
|
||||
if (path == nil || [path isEqual: @""] == YES)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue