From fd3d4ef60bab6a28cab85724d5a56a31a2573c5f Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Tue, 15 Apr 2008 19:42:09 +0000 Subject: build linux specific part only on linux --- src/tunDevice.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/tunDevice.cpp b/src/tunDevice.cpp index 78b3d19..b3c07b0 100644 --- a/src/tunDevice.cpp +++ b/src/tunDevice.cpp @@ -93,9 +93,13 @@ TunDevice::TunDevice(const char* dev_name,const char* dev_type, const char* ifcf // rp = inet_addr("192.168.199.1"); dev_ = init_tun(dev_name, dev_type, ifcfg_lp, ifcfg_rnmp, lp, rp, 0, NULL); - struct frame frame; // just for win32 - struct tuntap_options options; // win32 & linux - options.txqueuelen = 100; // just for linux + struct frame frame; + struct tuntap_options options; + +#ifdef TARGET_LINUX + options.txqueuelen = 100; +#endif + init_tun_post(dev_, &frame, &options); if(!dev_) throw std::runtime_error("can't init tun/tap device"); -- cgit v1.2.3