diff options
author | Christian Pointner <equinox@anytun.org> | 2008-02-24 00:07:01 +0000 |
---|---|---|
committer | Christian Pointner <equinox@anytun.org> | 2008-02-24 00:07:01 +0000 |
commit | 97d40fa80b08194c043a64d2352ca2cbc9be2873 (patch) | |
tree | 1819295d33262b386e2c333258bc9f6fd1c07a0b /tunDevice.cpp | |
parent | - keyderivation and cipher should work now (diff) |
bugfix@ sender and receiver reset packet size at begin of loop
bugfix@ keyDerivation
key_derivation_rate
Diffstat (limited to 'tunDevice.cpp')
-rw-r--r-- | tunDevice.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tunDevice.cpp b/tunDevice.cpp index 81f4cbb..b1ba686 100644 --- a/tunDevice.cpp +++ b/tunDevice.cpp @@ -110,7 +110,7 @@ TunDevice::~TunDevice() close_tun(dev_); } -short TunDevice::read(Buffer& buf) +short TunDevice::read(u_int8_t* buf, u_int32_t len) { if(!dev_) return -1; @@ -121,15 +121,15 @@ short TunDevice::read(Buffer& buf) pfd[0].revents = 0; poll(pfd, 1, -1); Lock lock(io_mutex_); - return read_tun(dev_, buf, buf.getLength()); + return read_tun(dev_, buf, len); } -int TunDevice::write(Buffer& buf) +int TunDevice::write(u_int8_t* buf, u_int32_t len) { if(!dev_) return -1; Lock lock(io_mutex_); - return write_tun(dev_, buf, buf.getLength()); + return write_tun(dev_, buf, len); } char* TunDevice::getActualName() |