Added error message for improperly formatted port/protocol string.

Thanks to David for finding this problem.
This commit is contained in:
doug 2008-05-28 22:25:05 +00:00
parent bbc2196eea
commit 29d2b20c98

View file

@ -2321,7 +2321,10 @@ static void getpts_aux(const char *origexpr, int nested, u8 *porttbl, int range_
/* Find the next range */
while(isspace((int) *current_range)) current_range++;
if (*current_range == ']') return;
if (*current_range == ']') {
if (!nested) fatal("Unexpected ] character in port/protocol specification");
return;
}
if (*current_range && *current_range != ',') {
fatal("Error #488: Your port specifications are illegal. Example of proper form: \"%s\"", syntax_example);