diff options
Diffstat (limited to 'src/linux')
-rw-r--r-- | src/linux/tunDevice.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/linux/tunDevice.cpp b/src/linux/tunDevice.cpp index 8fde8ae..8ab7ff8 100644 --- a/src/linux/tunDevice.cpp +++ b/src/linux/tunDevice.cpp @@ -127,6 +127,9 @@ int TunDevice::write(u_int8_t* buf, u_int32_t len) if(fd_ < 0) return -1; + if(!buf) + return 0; + if(with_pi_) { struct iovec iov[2]; |