diff options
author | Hongwei Wang <hongweiw@google.com> | 2015-07-16 14:16:51 -0700 |
---|---|---|
committer | Hongwei Wang <hongweiw@google.com> | 2015-07-16 14:16:51 -0700 |
commit | d423f3c2fdb9f6ca8ed3cfa16f51a9046ac35e0a (patch) | |
tree | 93c64c8ffe1469bed8ac20a8f4b056b6f8408fbe /src/core | |
parent | 2f89e400bee1f26704e544371c10d082593f8bfa (diff) |
Fix authority in uri_parser
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/client_config/uri_parser.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/client_config/uri_parser.c b/src/core/client_config/uri_parser.c index 776a255923..615aa4eaf0 100644 --- a/src/core/client_config/uri_parser.c +++ b/src/core/client_config/uri_parser.c @@ -99,7 +99,7 @@ grpc_uri *grpc_uri_parse(const char *uri_text, int suppress_errors) { if (uri_text[scheme_end + 1] == '/' && uri_text[scheme_end + 2] == '/') { authority_begin = scheme_end + 3; for (i = authority_begin; uri_text[i] != 0; i++) { - if (uri_text[i] == '/') { + if (uri_text[i] == '/' && authority_end == -1) { authority_end = i; } if (uri_text[i] == '?') { |