summaryrefslogtreecommitdiffstats
path: root/src/platform/udp.rs
diff options
context:
space:
mode:
authorMathias Hall-Andersen <mathias@hall-andersen.dk>2020-01-30 14:57:00 +0100
committerMathias Hall-Andersen <mathias@hall-andersen.dk>2020-01-30 14:57:00 +0100
commit605cc656ad235d09ba6cd12d03dee2c5e0a9a80a (patch)
tree1959f8597d27779680fd326c4a9fd6eba272f7eb /src/platform/udp.rs
parentFix typoes (diff)
downloadwireguard-rs-605cc656ad235d09ba6cd12d03dee2c5e0a9a80a.tar.xz
wireguard-rs-605cc656ad235d09ba6cd12d03dee2c5e0a9a80a.zip
Clear src when sendmsg fails with EINVAL
Diffstat (limited to 'src/platform/udp.rs')
-rw-r--r--src/platform/udp.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/platform/udp.rs b/src/platform/udp.rs
index 4685a1e..e1180fb 100644
--- a/src/platform/udp.rs
+++ b/src/platform/udp.rs
@@ -10,7 +10,7 @@ pub trait Reader<E: Endpoint>: Send + Sync {
pub trait Writer<E: Endpoint>: Send + Sync + Clone + 'static {
type Error: Error;
- fn write(&self, buf: &[u8], dst: &E) -> Result<(), Self::Error>;
+ fn write(&self, buf: &[u8], dst: &mut E) -> Result<(), Self::Error>;
}
pub trait UDP: Send + Sync + 'static {