From b8d3a31aa7f9d93e701cfd441d079ef0c22c9262 Mon Sep 17 00:00:00 2001
From: Craig Tiller <ctiller@google.com>
Date: Fri, 19 Jun 2015 17:27:53 -0700
Subject: [PATCH] Always use the first status code received

---
 src/core/surface/call.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/core/surface/call.c b/src/core/surface/call.c
index ad55ef6601..6e2714db0b 100644
--- a/src/core/surface/call.c
+++ b/src/core/surface/call.c
@@ -405,6 +405,8 @@ void grpc_call_internal_unref(grpc_call *c, int allow_immediate_deletion) {
 
 static void set_status_code(grpc_call *call, status_source source,
                             gpr_uint32 status) {
+  if (call->status[source].is_set) return;
+
   call->status[source].is_set = 1;
   call->status[source].code = status;
 
-- 
GitLab