diff options
author | jjako <jjako> | 2003-07-06 19:33:18 +0000 |
---|---|---|
committer | jjako <jjako> | 2003-07-06 19:33:18 +0000 |
commit | 88c2216e8eec9be3a3aa08f1020d045a31d291e1 (patch) | |
tree | 22a912cfe2e89cf7b281b8fffe7211bb96b350ba /ggsn/ggsn.c | |
parent | cdbf5794ee373e7473911734116b8620f314da1d (diff) |
ippool improved
Diffstat (limited to 'ggsn/ggsn.c')
-rw-r--r-- | ggsn/ggsn.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ggsn/ggsn.c b/ggsn/ggsn.c index 7a20feb..ea5a196 100644 --- a/ggsn/ggsn.c +++ b/ggsn/ggsn.c @@ -109,7 +109,7 @@ int encaps_printf(void *p, void *packet, unsigned len) int delete_context(struct pdp_t *pdp) { if (debug) printf("Deleting PDP context\n"); - ippool_freeip((struct ippoolm_t *) pdp->peer); + ippool_freeip(ippool, (struct ippoolm_t *) pdp->peer); return 0; } @@ -254,6 +254,7 @@ int main(int argc, char **argv) exit(1); } + /* net */ /* Store net as in_addr net and mask */ if (args_info.net_arg) { @@ -271,7 +272,7 @@ int main(int argc, char **argv) /* dynip */ if (!args_info.dynip_arg) { - if (ippool_new(&ippool, args_info.net_arg, + if (ippool_new(&ippool, args_info.net_arg, NULL, 1, 0, IPPOOL_NONETWORK | IPPOOL_NOBROADCAST)) { sys_err(LOG_ERR, __FILE__, __LINE__, 0, "Failed to allocate IP pool!"); @@ -279,7 +280,7 @@ int main(int argc, char **argv) } } else { - if (ippool_new(&ippool, args_info.dynip_arg, + if (ippool_new(&ippool, args_info.dynip_arg, NULL, 1 ,0, IPPOOL_NONETWORK | IPPOOL_NOBROADCAST)) { sys_err(LOG_ERR, __FILE__, __LINE__, 0, "Failed to allocate IP pool!"); |