diff options
author | Simon Rozman <simon@rozman.si> | 2019-02-20 13:12:08 +0100 |
---|---|---|
committer | Simon Rozman <simon@rozman.si> | 2019-02-20 13:12:08 +0100 |
commit | b7025b56274f65080d3c20a34a35ec5a07422792 (patch) | |
tree | 07b5848db7cf01fed1fd28307d6675619bebfff8 /allowedips_test.go | |
parent | 6581cfb8850ee98dc9ee7aceb76e51b0de904db1 (diff) |
wintun: Add TUN device locking
In case reading from TUN device detected TUN device was closed, it
closed the file handle and set tunFile to nil. The tunFile is
automatically reopened on retry, but... If another packet comes in the
WireGuard calls Write() method. With tunFile set to nil, this will
cause access violation.
Therefore, locking was introduced.
Signed-off-by: Simon Rozman <simon@rozman.si>
Diffstat (limited to 'allowedips_test.go')
0 files changed, 0 insertions, 0 deletions