git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3228 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1998-11-18 08:48:26 +00:00
parent 5700c80d27
commit 087bd3a593

View file

@ -943,39 +943,41 @@ init(int argc, char** argv)
int
main(int argc, char** argv)
{
init(argc, argv);
init(argc, argv);
[NSObject enableDoubleReleaseCheck: YES];
// [NSObject enableDoubleReleaseCheck: YES];
server = [[PasteboardServer alloc] init];
server = [[PasteboardServer alloc] init];
if (server == nil) {
NSLog(@"Unable to create server object.\n");
exit(1);
if (server == nil)
{
NSLog(@"Unable to create server object.\n");
exit(1);
}
/* Register a connection that provides the server object to the network */
conn = [NSConnection newRegisteringAtName:PBSNAME
withRootObject:server];
/* Register a connection that provides the server object to the network */
conn = [NSConnection newRegisteringAtName:PBSNAME
withRootObject:server];
if (conn == nil) {
NSLog(@"Unable to register with name server.\n");
exit(1);
if (conn == nil)
{
NSLog(@"Unable to register with name server.\n");
exit(1);
}
[conn setDelegate:server];
[NotificationDispatcher
addObserver: server
selector: @selector(connectionBecameInvalid:)
name: NSConnectionDidDieNotification
object: conn];
[conn setDelegate:server];
[NotificationDispatcher addObserver: server
selector: @selector(connectionBecameInvalid:)
name: NSConnectionDidDieNotification
object: conn];
if (verbose) {
NSLog(@"GNU pasteboard server startup.\n");
if (verbose)
{
NSLog(@"GNU pasteboard server startup.\n");
}
[[NSRunLoop currentRunLoop] run];
[[NSRunLoop currentRunLoop] run];
exit(0);
exit(0);
}