summary refs log tree commit diff
path: root/crypto/src/tls/ByteQueue.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/tls/ByteQueue.cs')
-rw-r--r--crypto/src/tls/ByteQueue.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/src/tls/ByteQueue.cs b/crypto/src/tls/ByteQueue.cs
index a92f79baf..6d29a2d3e 100644
--- a/crypto/src/tls/ByteQueue.cs
+++ b/crypto/src/tls/ByteQueue.cs
@@ -164,7 +164,7 @@ namespace Org.BouncyCastle.Tls
             if ((m_available - skip) < buffer.Length)
                 throw new InvalidOperationException("Not enough data to read");
 
-            buffer.CopyFrom(m_databuf.AsSpan(m_skipped + skip));
+            m_databuf.AsSpan(m_skipped + skip, buffer.Length).CopyTo(buffer);
         }
 #endif