aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/send.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/send.rs b/src/send.rs
index 741c542..0bbce47 100644
--- a/src/send.rs
+++ b/src/send.rs
@@ -51,6 +51,10 @@ impl<S: UdpSender> RudpShare<S> {
}
pub async fn send_raw(&self, data: &[u8]) -> io::Result<()> {
+ if data.len() > UDP_PKT_SIZE {
+ panic!("splitting packets is not implemented yet");
+ }
+
self.udp_tx.send(data).await
}
}