mirror of
https://github.com/gnustep/libs-steptalk.git
synced 2025-02-16 00:11:29 +00:00
Check the result of the super class initializer and assign it to self.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/steptalk/trunk@36407 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
81df64e7ab
commit
d51cc43755
2 changed files with 23 additions and 17 deletions
|
@ -1,3 +1,9 @@
|
|||
2013-03-23 Wolfgang Lux <wlux@uni-muenster.de>
|
||||
|
||||
* Tools/STEnvironmentProcess.m (initWithDescriptionName:):
|
||||
Check the result of the super class initializer and assign it to
|
||||
self.
|
||||
|
||||
2013-03-23 Wolfgang Lux <wolfgang.lux@gmail.com>
|
||||
|
||||
* Frameworks/StepTalk/STActor.m (-init, -initWithEnvironment:,
|
||||
|
|
|
@ -7,25 +7,25 @@
|
|||
@implementation STEnvironmentProcess
|
||||
- initWithDescriptionName:(NSString *)descName
|
||||
{
|
||||
STEnvironmentDescription *desc;
|
||||
|
||||
self = [super init];
|
||||
|
||||
if(descName)
|
||||
if ((self = [super init]) != nil)
|
||||
{
|
||||
NSLog(@"Creating environment from description '%@'", descName);
|
||||
desc = [STEnvironmentDescription descriptionWithName:descName];
|
||||
environment = [[STEnvironment alloc] initWithDescription:desc];
|
||||
}
|
||||
else
|
||||
{
|
||||
environment = [[STEnvironment alloc] initWithDefaultDescription];
|
||||
}
|
||||
|
||||
/* FIXME: use some configurable mechanism */
|
||||
[environment setObject:environment forName:@"Environment"];
|
||||
[environment loadModule:@"SimpleTranscript"];
|
||||
STEnvironmentDescription *desc;
|
||||
|
||||
if (descName)
|
||||
{
|
||||
NSLog(@"Creating environment from description '%@'", descName);
|
||||
desc = [STEnvironmentDescription descriptionWithName:descName];
|
||||
environment = [[STEnvironment alloc] initWithDescription:desc];
|
||||
}
|
||||
else
|
||||
{
|
||||
environment = [[STEnvironment alloc] initWithDefaultDescription];
|
||||
}
|
||||
|
||||
/* FIXME: use some configurable mechanism */
|
||||
[environment setObject:environment forName:@"Environment"];
|
||||
[environment loadModule:@"SimpleTranscript"];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
- (void)dealloc
|
||||
|
|
Loading…
Reference in a new issue