summaryrefslogtreecommitdiff
path: root/src/options.cpp
diff options
context:
space:
mode:
authorChristian Pointner <equinox@anytun.org>2008-05-09 18:19:05 +0000
committerChristian Pointner <equinox@anytun.org>2008-05-09 18:19:05 +0000
commite9104d332552bc617b30bc8b7db0ccfac53bff72 (patch)
tree4f95804bb4236782ac9fa080040dbe5fff3a660a /src/options.cpp
parentbugfix @ tundevice and ipv6 (diff)
linux tun/tap device works now with tun *and* tap
TODO: ifconfig
Diffstat (limited to 'src/options.cpp')
-rw-r--r--src/options.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/options.cpp b/src/options.cpp
index 3b7e468..798504b 100644
--- a/src/options.cpp
+++ b/src/options.cpp
@@ -66,7 +66,7 @@ Options::Options() : key_(u_int32_t(0)), salt_(u_int32_t(0))
remote_sync_addr_ = "";
remote_addr_ = "";
remote_port_ = 4444;
- dev_name_ = "tun";
+ dev_name_ = "";
dev_type_ = "";
ifconfig_param_local_ = "";
ifconfig_param_remote_netmask_ = "";
@@ -194,6 +194,9 @@ bool Options::parse(int argc, char* argv[])
if((cipher_ != "null" || auth_algo_ != "null") && kd_prf_ == "null")
kd_prf_ = "aes-ctr";
+ if(dev_name_ == "" && dev_type_ == "")
+ dev_type_ = "tun";
+
while(!host_port_queue.empty())
{
std::stringstream tmp_stream(host_port_queue.front());