Skip to content

Commit

Permalink
use new ArraySegment send from windows only
Browse files Browse the repository at this point in the history
  • Loading branch information
bculberson committed Aug 21, 2012
1 parent e85a294 commit 4ab3545
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/ServiceStack.Redis/RedisNativeClient_Utils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,17 @@ public void WriteToSendBuffer(byte[] cmdBytes)

public void FlushSendBuffer()
{
socket.Send(cmdBuffer, SocketFlags.None);
if (Env.IsMono)
{
foreach (var buffer in cmdBuffer)
{
socket.Send(buffer.Array, buffer.Array.Length, SocketFlags.None);
}
}
else
{
socket.Send(cmdBuffer, SocketFlags.None);
}
cmdBuffer.Clear();
}
/// <summary>
Expand Down

0 comments on commit 4ab3545

Please sign in to comment.