diff --git a/Console.m b/Console.m index 13366c1..c65b8c3 100644 --- a/Console.m +++ b/Console.m @@ -47,6 +47,7 @@ inner_main() cmdVersion(@"$Date: 2012-02-13 08:11:49 +0000 (Mon, 13 Feb 2012) $ $Revision: 65934 $"); defs = [NSDictionary dictionaryWithObjectsAndKeys: + @"NO", @"Daemon", #if defined(EC_REGISTRATION_DOMAIN) EC_REGISTRATION_DOMAIN #endif diff --git a/EcConsole.m b/EcConsole.m index 1552fe4..fa85690 100644 --- a/EcConsole.m +++ b/EcConsole.m @@ -690,7 +690,12 @@ static BOOL commandIsRepeat (NSString *string) appDefaults = [NSDictionary dictionaryWithObjects: objects forKeys: keys count: NUMARGS]; - self = [super initWithDefaults: appDefaults]; + return [self initWithDefaults: appDefaults]; +} + +- (id) initWithDefaults: (NSDictionary*)defs +{ + self = [super initWithDefaults: defs]; if (self) { NSUserDefaults *defs = [self cmdDefaults]; diff --git a/local.make b/local.make index b7a9421..462887d 100644 --- a/local.make +++ b/local.make @@ -29,7 +29,6 @@ ECCL_CPPFLAGS += \ '-DEC_DEFAULTS_PREFIX=@"BS"'\ '-DEC_DEFAULTS_STRICT=NO'\ '-DEC_EFFECTIVE_USER=@"brains99"'\ - '-DEC_REGISTRATION_DOMAIN=@"1.3.6.1.4.1.39543.3.0.1",@"TrapOID",@"1.3.6.1.4.1.39543.1",@"AlarmsOID",@"1.3.6.1.4.1.39543.2",@"ObjectsOID",'\ # Command_CPPFLAGS ... # Allow an alternative base class to be specified ... @@ -49,6 +48,9 @@ Console_CPPFLAGS += \ # Allow an alternative base class to be specified ... # The file containing that class will also need to be added to the build/link # flags if it's not in the standard libraries. +# The Control server contains the SNMP alarming support, so we may want to +# define the OID settings for that. Control_CPPFLAGS += \ '-DEC_BASE_CLASS=EcControl'\ + '-DEC_REGISTRATION_DOMAIN=@"1.3.6.1.4.1.39543.3.0.1",@"TrapOID",@"1.3.6.1.4.1.39543.1",@"AlarmsOID",@"1.3.6.1.4.1.39543.2",@"ObjectsOID",'\