diff options
author | Rémy Coutable <remy@rymai.me> | 2018-01-25 09:16:18 +0000 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2018-01-25 09:16:18 +0000 |
commit | 567b3826a99e5573f4db7c033ce59cbf0fd640c7 (patch) | |
tree | 09804ea3d7d18b9b7a6d26a411bba5aa4306bf67 /lib | |
parent | aff9ecefb8a2c0e3b6816a4632c8433940dd6e88 (diff) | |
parent | b33e7281ffef39058bcef4e741060a703cfaf02e (diff) | |
download | gitlab-ce-567b3826a99e5573f4db7c033ce59cbf0fd640c7.tar.gz |
Merge branch '42161-gitaly-commitservice-encoding-undefinedconversionerror-u-c124-from-utf-8-to-ascii-8bit' into 'master'
Resolve "Gitaly::CommitService: Encoding::UndefinedConversionError: U+C124 from UTF-8 to ASCII-8BIT"
Closes #42161
See merge request gitlab-org/gitlab-ce!16637
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/gitaly_client/commit_service.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/gitaly_client/commit_service.rb b/lib/gitlab/gitaly_client/commit_service.rb index 2231371cfa7..33a8d3e5612 100644 --- a/lib/gitlab/gitaly_client/commit_service.rb +++ b/lib/gitlab/gitaly_client/commit_service.rb @@ -125,11 +125,11 @@ module Gitlab def commit_count(ref, options = {}) request = Gitaly::CountCommitsRequest.new( repository: @gitaly_repo, - revision: ref + revision: encode_binary(ref) ) request.after = Google::Protobuf::Timestamp.new(seconds: options[:after].to_i) if options[:after].present? request.before = Google::Protobuf::Timestamp.new(seconds: options[:before].to_i) if options[:before].present? - request.path = options[:path] if options[:path].present? + request.path = encode_binary(options[:path]) if options[:path].present? request.max_count = options[:max_count] if options[:max_count].present? GitalyClient.call(@repository.storage, :commit_service, :count_commits, request, timeout: GitalyClient.medium_timeout).count |