From 87dae2cee395385aae6343157a3fb5a4db0d6d79 Mon Sep 17 00:00:00 2001 From: Anoop Saldanha Date: Tue, 22 May 2012 00:55:02 +0530 Subject: [PATCH 3/3] bug #454 - rebase fix. Also use better error code to indicate invalid address var yaml entry --- src/detect-engine-address.c | 2 +- src/detect-engine-port.c | 2 +- src/util-error.c | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/detect-engine-address.c b/src/detect-engine-address.c index ac71a32..a1c091c 100644 --- a/src/detect-engine-address.c +++ b/src/detect-engine-address.c @@ -1257,7 +1257,7 @@ int DetectAddressTestConfVars(void) } if (DetectAddressIsCompleteIPSpace(ghn)) { - SCLogError(SC_ERR_ADDRESS_ENGINE_GENERIC, + SCLogError(SC_ERR_INVALID_YAML_CONF_ENTRY, "Address var - \"%s\" has the complete IP space negated " "with it's value \"%s\". Rule address range is NIL. " "Probably have a !any or an address range that supplies " diff --git a/src/detect-engine-port.c b/src/detect-engine-port.c index 07295ae..2b231b3 100644 --- a/src/detect-engine-port.c +++ b/src/detect-engine-port.c @@ -1314,7 +1314,7 @@ int DetectPortTestConfVars(void) } if (DetectPortIsCompletePortSpace(ghn)) { - SCLogError(SC_ERR_PORT_ENGINE_GENERIC, + SCLogError(SC_ERR_INVALID_YAML_CONF_ENTRY, "Port var - \"%s\" has the complete Port range negated " "with it's value \"%s\". Port space range is NIL. " "Probably have a !any or a port range that supplies " diff --git a/src/util-error.c b/src/util-error.c index 80e6377..9ef6a1a 100644 --- a/src/util-error.c +++ b/src/util-error.c @@ -102,7 +102,6 @@ const char * SCErrorToString(SCError err) CASE_CODE (SC_ERR_ADDRESS_ENGINE_GENERIC); CASE_CODE (SC_ERR_PORT_ENGINE_GENERIC); CASE_CODE (SC_ERR_FAST_LOG_GENERIC); - CASE_CODE (SC_ERR_ADDRESS_ENGINE_GENERIC); CASE_CODE (SC_ERR_IPONLY_RADIX); CASE_CODE (SC_ERR_DEBUG_LOG_GENERIC); CASE_CODE (SC_ERR_UNIFIED_LOG_GENERIC); -- 1.7.1