More mask code. Identical, in fact.
authorcmiller <cmiller>
Wed, 19 Feb 2003 15:28:07 +0000 (15:28 +0000)
committercmiller <cmiller>
Wed, 19 Feb 2003 15:28:07 +0000 (15:28 +0000)
TODO:  Investigate code duplication in client.c and mainconfig.c

src/main/mainconfig.c

index f09c473..17ea665 100644 (file)
@@ -622,7 +622,7 @@ static int generate_clients(const char *filename)
                        int i, mask_length;
 
                        mask_length = atoi(netmask + 1);
-                       if ((mask_length <= 0) || (mask_length > 32)) {
+                       if ((mask_length < 0) || (mask_length > 32)) {
                                radlog(L_ERR, "%s[%d]: Invalid value '%s' for IP network mask.",
                                                filename, cf_section_lineno(cs), netmask + 1);
                                return -1;