summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Pointner <equinox@anytun.org>2009-01-22 13:46:45 +0000
committerChristian Pointner <equinox@anytun.org>2009-01-22 13:46:45 +0000
commit05b8a93f8a86b88da8556fcdf51132784a3aa246 (patch)
treecc645383a039435a6275e4ffdabc8fcf7583eb74 /src
parentwindows tap driver version gets checked now (diff)
setting device status to up after ifconfig
Diffstat (limited to 'src')
-rw-r--r--src/anytun.suobin59392 -> 57856 bytes
-rw-r--r--src/win32/tunDevice.cpp6
2 files changed, 3 insertions, 3 deletions
diff --git a/src/anytun.suo b/src/anytun.suo
index b53dcf1..71a022b 100644
--- a/src/anytun.suo
+++ b/src/anytun.suo
Binary files differ
diff --git a/src/win32/tunDevice.cpp b/src/win32/tunDevice.cpp
index 2e95966..94fc657 100644
--- a/src/win32/tunDevice.cpp
+++ b/src/win32/tunDevice.cpp
@@ -96,6 +96,9 @@ TunDevice::TunDevice(std::string dev_name, std::string dev_type, std::string ifc
}
}
+ if(ifcfg_lp != "" && ifcfg_rnmp != "")
+ do_ifconfig();
+
int status = true;
err = performIoControl(TAP_IOCTL_SET_MEDIA_STATUS, &status, sizeof(status), &status, sizeof(status));
if(err != ERROR_SUCCESS) {
@@ -105,9 +108,6 @@ TunDevice::TunDevice(std::string dev_name, std::string dev_type, std::string ifc
throw std::runtime_error(msg.str());
}
- if(ifcfg_lp != "" && ifcfg_rnmp != "")
- do_ifconfig();
-
roverlapped_.hEvent = CreateEvent(NULL, TRUE, FALSE, NULL);
woverlapped_.hEvent = CreateEvent(NULL, TRUE, FALSE, NULL);
}