aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/csharp/Grpc.Core/Internal/ClientResponseStream.cs
diff options
context:
space:
mode:
authorGravatar Jan Tattermusch <jtattermusch@google.com>2016-05-02 17:17:18 -0700
committerGravatar Jan Tattermusch <jtattermusch@google.com>2016-05-03 07:59:59 -0700
commit96f21a27cb7975d52aa92197536eef0ad8dca455 (patch)
tree9ab394f79d21761528842ffae7e62f32ddea5e08 /src/csharp/Grpc.Core/Internal/ClientResponseStream.cs
parenta83ad2aa65a04d16b484e7c4373b7db5575221a4 (diff)
make end-of-stream idempotent
Diffstat (limited to 'src/csharp/Grpc.Core/Internal/ClientResponseStream.cs')
-rw-r--r--src/csharp/Grpc.Core/Internal/ClientResponseStream.cs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/csharp/Grpc.Core/Internal/ClientResponseStream.cs b/src/csharp/Grpc.Core/Internal/ClientResponseStream.cs
index d6e34a0f04..ad9423ff58 100644
--- a/src/csharp/Grpc.Core/Internal/ClientResponseStream.cs
+++ b/src/csharp/Grpc.Core/Internal/ClientResponseStream.cs
@@ -68,9 +68,7 @@ namespace Grpc.Core.Internal
{
throw new InvalidOperationException("Cancellation of individual reads is not supported.");
}
- var taskSource = new AsyncCompletionTaskSource<TResponse>();
- call.StartReadMessage(taskSource.CompletionDelegate);
- var result = await taskSource.Task.ConfigureAwait(false);
+ var result = await call.ReadMessageAsync().ConfigureAwait(false);
this.current = result;
if (result == null)