ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/gvpe/src/conf.C
(Generate patch)

Comparing gvpe/src/conf.C (file contents):
Revision 1.59 by root, Tue Dec 4 10:29:43 2012 UTC vs.
Revision 1.60 by root, Sat Jul 13 04:10:29 2013 UTC

161 dns_send_interval = DEFAULT_DNS_SEND_INTERVAL; 161 dns_send_interval = DEFAULT_DNS_SEND_INTERVAL;
162 dns_overlap_factor = DEFAULT_DNS_OVERLAP_FACTOR; 162 dns_overlap_factor = DEFAULT_DNS_OVERLAP_FACTOR;
163 dns_max_outstanding = DEFAULT_DNS_MAX_OUTSTANDING; 163 dns_max_outstanding = DEFAULT_DNS_MAX_OUTSTANDING;
164#endif 164#endif
165 165
166 conf.pidfilename = strdup (LOCALSTATEDIR "/run/gvpe.pid"); 166 pidfilename = strdup (LOCALSTATEDIR "/run/gvpe.pid");
167 seed_dev = strdup ("/dev/urandom");
168 reseed = DEFAULT_RESEED;
167} 169}
168 170
169void 171void
170configuration::cleanup () 172configuration::cleanup ()
171{ 173{
172 if (rsa_key) 174 if (rsa_key)
173 RSA_free (rsa_key); 175 RSA_free (rsa_key);
174 176
175 rsa_key = 0; 177 rsa_key = 0;
176 178
179 free (seed_dev); seed_dev = 0;
177 free (pidfilename); pidfilename = 0; 180 free (pidfilename); pidfilename = 0;
178 free (ifname); ifname = 0; 181 free (ifname); ifname = 0;
179#if ENABLE_HTTP_PROXY 182#if ENABLE_HTTP_PROXY
180 free (proxy_host); proxy_host = 0; 183 free (proxy_host); proxy_host = 0;
181 free (proxy_auth); proxy_auth = 0; 184 free (proxy_auth); proxy_auth = 0;
351 conf.keepalive = atoi (val); 354 conf.keepalive = atoi (val);
352 else if (!strcmp (var, "mtu")) 355 else if (!strcmp (var, "mtu"))
353 conf.mtu = atoi (val); 356 conf.mtu = atoi (val);
354 else if (!strcmp (var, "nfmark")) 357 else if (!strcmp (var, "nfmark"))
355 conf.nfmark = atoi (val); 358 conf.nfmark = atoi (val);
359 else if (!strcmp (var, "seed-device"))
360 free (conf.seed_dev), conf.seed_dev = strdup (val);
361 else if (!strcmp (var, "seed-interval"))
362 conf.reseed = atoi (val);
356 else if (!strcmp (var, "if-up")) 363 else if (!strcmp (var, "if-up"))
357 free (conf.script_if_up), conf.script_if_up = strdup (val); 364 free (conf.script_if_up), conf.script_if_up = strdup (val);
358 else if (!strcmp (var, "node-up")) 365 else if (!strcmp (var, "node-up"))
359 free (conf.script_node_up), conf.script_node_up = strdup (val); 366 free (conf.script_node_up), conf.script_node_up = strdup (val);
360 else if (!strcmp (var, "node-change")) 367 else if (!strcmp (var, "node-change"))

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines