mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-25 01:31:08 +00:00
Don't insist on tools being in system domain
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@27149 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
933c52af50
commit
3937ca0b97
2 changed files with 75 additions and 48 deletions
|
@ -25,25 +25,26 @@
|
||||||
$Date$ $Revision$
|
$Date$ $Revision$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "config.h"
|
#import "config.h"
|
||||||
#include "GNUstepBase/preface.h"
|
#import "GNUstepBase/preface.h"
|
||||||
#include "Foundation/NSObject.h"
|
#import "Foundation/NSObject.h"
|
||||||
#include "Foundation/NSConnection.h"
|
#import "Foundation/NSConnection.h"
|
||||||
#include "Foundation/NSDistantObject.h"
|
#import "Foundation/NSDistantObject.h"
|
||||||
#include "Foundation/NSException.h"
|
#import "Foundation/NSException.h"
|
||||||
#include "Foundation/NSArchiver.h"
|
#import "Foundation/NSFileManager.h"
|
||||||
#include "Foundation/NSNotification.h"
|
#import "Foundation/NSArchiver.h"
|
||||||
#include "Foundation/NSDate.h"
|
#import "Foundation/NSNotification.h"
|
||||||
#include "Foundation/NSPathUtilities.h"
|
#import "Foundation/NSDate.h"
|
||||||
#include "Foundation/NSRunLoop.h"
|
#import "Foundation/NSPathUtilities.h"
|
||||||
#include "Foundation/NSTask.h"
|
#import "Foundation/NSRunLoop.h"
|
||||||
#include "Foundation/NSDistributedNotificationCenter.h"
|
#import "Foundation/NSTask.h"
|
||||||
#include "Foundation/NSUserDefaults.h"
|
#import "Foundation/NSDistributedNotificationCenter.h"
|
||||||
#include "Foundation/NSHost.h"
|
#import "Foundation/NSUserDefaults.h"
|
||||||
#include "Foundation/NSPortNameServer.h"
|
#import "Foundation/NSHost.h"
|
||||||
#include "Foundation/NSDebug.h"
|
#import "Foundation/NSPortNameServer.h"
|
||||||
#include "Foundation/NSThread.h"
|
#import "Foundation/NSDebug.h"
|
||||||
#include "../Tools/gdnc.h"
|
#import "Foundation/NSThread.h"
|
||||||
|
#import "../Tools/gdnc.h"
|
||||||
|
|
||||||
|
|
||||||
@interface NSDistributedNotificationCenter (Private)
|
@interface NSDistributedNotificationCenter (Private)
|
||||||
|
@ -694,11 +695,23 @@ static NSDistributedNotificationCenter *netCenter = nil;
|
||||||
NSString *cmd = nil;
|
NSString *cmd = nil;
|
||||||
NSArray *args = nil;
|
NSArray *args = nil;
|
||||||
NSDate *limit;
|
NSDate *limit;
|
||||||
|
NSEnumerator *enumerator;
|
||||||
|
NSString *path;
|
||||||
|
NSFileManager *mgr;
|
||||||
|
|
||||||
cmd = [[NSSearchPathForDirectoriesInDomains(
|
mgr = [NSFileManager defaultManager];
|
||||||
GSToolsDirectory, NSSystemDomainMask, YES) objectAtIndex: 0]
|
enumerator = [NSSearchPathForDirectoriesInDomains(
|
||||||
stringByAppendingPathComponent: @"gdnc"];
|
GSToolsDirectory, NSAllDomainsMask, YES) objectEnumerator];
|
||||||
|
while ((path = [enumerator nextObject]) != nil)
|
||||||
|
{
|
||||||
|
path = [path stringByAppendingPathComponent: @"gdnc"];
|
||||||
|
if ([mgr isExecutableFileAtPath: path])
|
||||||
|
{
|
||||||
|
cmd = path;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
NSDebugMLLog(@"NSDistributedNotificationCenter",
|
NSDebugMLLog(@"NSDistributedNotificationCenter",
|
||||||
@"\nI couldn't contact the notification server for %@ -\n"
|
@"\nI couldn't contact the notification server for %@ -\n"
|
||||||
@"so I'm attempting to to start one - which will take a few seconds.\n"
|
@"so I'm attempting to to start one - which will take a few seconds.\n"
|
||||||
|
|
|
@ -24,29 +24,30 @@
|
||||||
$Date$ $Revision$
|
$Date$ $Revision$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "config.h"
|
#import "config.h"
|
||||||
#include "Foundation/NSString.h"
|
#import "Foundation/NSString.h"
|
||||||
#include "Foundation/NSData.h"
|
#import "Foundation/NSData.h"
|
||||||
#include "Foundation/NSByteOrder.h"
|
#import "Foundation/NSByteOrder.h"
|
||||||
#include "Foundation/NSException.h"
|
#import "Foundation/NSException.h"
|
||||||
#include "Foundation/NSAutoreleasePool.h"
|
#import "Foundation/NSAutoreleasePool.h"
|
||||||
#include "Foundation/NSLock.h"
|
#import "Foundation/NSFileManager.h"
|
||||||
#include "Foundation/NSFileHandle.h"
|
#import "Foundation/NSLock.h"
|
||||||
#include "Foundation/NSRunLoop.h"
|
#import "Foundation/NSFileHandle.h"
|
||||||
#include "Foundation/NSNotification.h"
|
#import "Foundation/NSRunLoop.h"
|
||||||
#include "Foundation/NSNotificationQueue.h"
|
#import "Foundation/NSNotification.h"
|
||||||
#include "Foundation/NSPort.h"
|
#import "Foundation/NSNotificationQueue.h"
|
||||||
#include "Foundation/NSMapTable.h"
|
#import "Foundation/NSPort.h"
|
||||||
#include "Foundation/NSSet.h"
|
#import "Foundation/NSMapTable.h"
|
||||||
#include "Foundation/NSHost.h"
|
#import "Foundation/NSSet.h"
|
||||||
#include "Foundation/NSTask.h"
|
#import "Foundation/NSHost.h"
|
||||||
#include "Foundation/NSDate.h"
|
#import "Foundation/NSTask.h"
|
||||||
#include "Foundation/NSTimer.h"
|
#import "Foundation/NSDate.h"
|
||||||
#include "Foundation/NSPathUtilities.h"
|
#import "Foundation/NSTimer.h"
|
||||||
#include "Foundation/NSPortNameServer.h"
|
#import "Foundation/NSPathUtilities.h"
|
||||||
#include "Foundation/NSDebug.h"
|
#import "Foundation/NSPortNameServer.h"
|
||||||
|
#import "Foundation/NSDebug.h"
|
||||||
|
|
||||||
#include "GSPortPrivate.h"
|
#import "GSPortPrivate.h"
|
||||||
|
|
||||||
#ifdef __MINGW32__
|
#ifdef __MINGW32__
|
||||||
#include <winsock2.h>
|
#include <winsock2.h>
|
||||||
|
@ -186,9 +187,22 @@ typedef enum {
|
||||||
[self close];
|
[self close];
|
||||||
if (launchCmd == nil)
|
if (launchCmd == nil)
|
||||||
{
|
{
|
||||||
launchCmd = RETAIN([[NSSearchPathForDirectoriesInDomains(
|
NSEnumerator *enumerator;
|
||||||
GSToolsDirectory, NSSystemDomainMask, YES) objectAtIndex: 0]
|
NSString *path;
|
||||||
stringByAppendingPathComponent: @"gdomap"]);
|
NSFileManager *mgr;
|
||||||
|
|
||||||
|
mgr = [NSFileManager defaultManager];
|
||||||
|
enumerator = [NSSearchPathForDirectoriesInDomains(
|
||||||
|
GSToolsDirectory, NSAllDomainsMask, YES) objectEnumerator];
|
||||||
|
while ((path = [enumerator nextObject]) != nil)
|
||||||
|
{
|
||||||
|
path = [path stringByAppendingPathComponent: @"gdomap"];
|
||||||
|
if ([mgr isExecutableFileAtPath: path])
|
||||||
|
{
|
||||||
|
launchCmd = path;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (state == GSPC_LOPEN && launchCmd != nil)
|
if (state == GSPC_LOPEN && launchCmd != nil)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue