whitequark před 7 roky
rodič
revize
8ee2f7bff5
2 změnil soubory, kde provedl 3 přidání a 3 odebrání
  1. 1 1
      src/socket/udp.rs
  2. 2 2
      src/storage/ring_buffer.rs

+ 1 - 1
src/socket/udp.rs

@@ -51,7 +51,7 @@ impl<'a> Resettable for PacketBuffer<'a> {
 }
 }
 
 
 /// An UDP packet ring buffer.
 /// An UDP packet ring buffer.
-pub type SocketBuffer<'a, 'b : 'a> = RingBuffer<'a, PacketBuffer<'b>>;
+pub type SocketBuffer<'a, 'b: 'a> = RingBuffer<'a, PacketBuffer<'b>>;
 
 
 /// An User Datagram Protocol socket.
 /// An User Datagram Protocol socket.
 ///
 ///

+ 2 - 2
src/storage/ring_buffer.rs

@@ -594,7 +594,7 @@ mod test {
 
 
     #[test]
     #[test]
     fn test_buffer_get_unallocated() {
     fn test_buffer_get_unallocated() {
-        let mut ring = RingBuffer::new(vec![b'.'; 12]);;
+        let mut ring = RingBuffer::new(vec![b'.'; 12]);
 
 
         assert_eq!(ring.get_unallocated(16, 4), b"");
         assert_eq!(ring.get_unallocated(16, 4), b"");
 
 
@@ -643,7 +643,7 @@ mod test {
 
 
     #[test]
     #[test]
     fn test_buffer_get_allocated() {
     fn test_buffer_get_allocated() {
-        let mut ring = RingBuffer::new(vec![b'.'; 12]);;
+        let mut ring = RingBuffer::new(vec![b'.'; 12]);
 
 
         assert_eq!(ring.get_allocated(16, 4), b"");
         assert_eq!(ring.get_allocated(16, 4), b"");
         assert_eq!(ring.get_allocated(0, 4),  b"");
         assert_eq!(ring.get_allocated(0, 4),  b"");