Fixing error code as discussed during the review.

pull/2847/head
Julien Boeuf 9 years ago
parent ca9460bc6d
commit 8f52853e13
  1. 4
      src/core/security/client_auth_filter.c

@ -183,7 +183,7 @@ static void on_host_checked(void *user_data, grpc_security_status status) {
char *error_msg;
gpr_asprintf(&error_msg, "Invalid host %s set in :authority metadata.",
grpc_mdstr_as_c_string(calld->host));
bubble_up_error(elem, GRPC_STATUS_FAILED_PRECONDITION, error_msg);
bubble_up_error(elem, GRPC_STATUS_INVALID_ARGUMENT, error_msg);
gpr_free(error_msg);
}
}
@ -253,7 +253,7 @@ static void auth_start_transport_op(grpc_call_element *elem,
gpr_asprintf(&error_msg,
"Invalid host %s set in :authority metadata.",
call_host);
bubble_up_error(elem, GRPC_STATUS_FAILED_PRECONDITION, error_msg);
bubble_up_error(elem, GRPC_STATUS_INVALID_ARGUMENT, error_msg);
gpr_free(error_msg);
}
return; /* early exit */

Loading…
Cancel
Save