--- libelwix/src/patricia.c 2013/05/26 20:03:19 1.1.1.1.6.1 +++ libelwix/src/patricia.c 2024/01/22 15:24:28 1.6 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: patricia.c,v 1.1.1.1.6.1 2013/05/26 20:03:19 misho Exp $ +* $Id: patricia.c,v 1.6 2024/01/22 15:24:28 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -12,7 +12,7 @@ terms: All of the documentation and software included in the ELWIX and AITNET Releases is copyrighted by ELWIX - Sofia/Bulgaria -Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 +Copyright 2004 - 2024 by Michael Pounov . All rights reserved. Redistribution and use in source and binary forms, with or without @@ -57,7 +57,7 @@ SUCH DAMAGE. */ #include "global.h" - +#ifdef PATRICIA_SUPPORT static int num_active_patricia; @@ -257,7 +257,7 @@ prefix_t *ascii2prefix(int family, char *string) memcpy(save, string, cp - string); save[cp - string] = 0; string = save; - if (bitlen < 0 || bitlen > maxbitlen) + if (bitlen > maxbitlen) bitlen = maxbitlen; } else bitlen = maxbitlen; @@ -926,3 +926,4 @@ patricia_node_t *try_search_best(patricia_tree_t *tree } /* } */ +#endif