Minor startup improvements etc.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@5683 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
richard 2000-01-07 10:42:12 +00:00
parent 8b5b7f5edb
commit 16976fdfb4
3 changed files with 16 additions and 10 deletions

View file

@ -41,11 +41,10 @@ char **NSArgv = NULL;
int
NSApplicationMain(int argc, const char **argv)
{
NSAutoreleasePool *pool;
NSDictionary *infoDict;
NSString *className;
Class appClass;
CREATE_AUTORELEASE_POOL(pool);
#if LIB_FOUNDATION_LIBRARY
extern char **environ;
@ -54,8 +53,6 @@ NSApplicationMain(int argc, const char **argv)
environment: environ];
#endif
pool = [NSAutoreleasePool new];
#ifndef NX_CURRENT_COMPILER_RELEASE
initialize_gnustep_backend();
#endif
@ -66,12 +63,15 @@ NSApplicationMain(int argc, const char **argv)
if (appClass == 0)
{
NSLog(@"Bad application class '%@' specified", className);
appClass = [NSApplication class];
}
[[appClass sharedApplication] run];
[pool release];
DESTROY(NSApp);
RELEASE(pool);
return 0;
}