make range allocation dynamic

This is a test fix after commit

5cbe8d07fb

to see what can be done. Truth is that not much. I could fix how
ranges are allocated, but the fact there is pointers to shared
networks and network names reallocating the memory spaces is not
really going to work. The only way to truly fix this issue is to
create better data structures. As you can expect that is a major
change, and will take some time to implement.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2011-04-10 19:12:29 +02:00
parent f6880ed5f4
commit b492802dfa
6 changed files with 33 additions and 17 deletions

View file

@ -13,7 +13,7 @@
**
** You should have received a copy of the GNU General Public License
** along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
*/
#ifndef DEFAULTS_H
# define DEFAULTS_H 1
@ -22,15 +22,12 @@
static const int MAXLEN = 1024;
/* Total number of characters in all shared network names */
static const int SHARED_NETWORKS_NAMES = 65536;
static const unsigned int SHARED_NETWORKS_NAMES = 65536;
/* Maximum number of shared networks */
static const int SHARED_NETWORKS = 8192;
static const unsigned int SHARED_NETWORKS = 8192;
/* Maximum number of ranges */
static const unsigned int RANGES = 65536;
unsigned int RANGES;
/* Merge sort split size */
static const int MIN_MERGE_SIZE = 8;
#endif /* DEFAULTS_H */
#endif /* DEFAULTS_H */