summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-15 07:16:04 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-15 07:16:04 +0000
commit991d39a9acca6e5c0e46dc6ac786fb188d82064c (patch)
tree4757535f02b85826e4325af16e470a5e86b225e3 /lib
parenteae0620e3a72be45596f897ffaaa322dcd92d6d9 (diff)
downloadredmine-991d39a9acca6e5c0e46dc6ac786fb188d82064c.tar.gz
redmine-991d39a9acca6e5c0e46dc6ac786fb188d82064c.zip
scm: cvs: convert encoding of command line arguments (#3462).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5462 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib')
-rw-r--r--lib/redmine/scm/adapters/cvs_adapter.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/redmine/scm/adapters/cvs_adapter.rb b/lib/redmine/scm/adapters/cvs_adapter.rb
index 7c1e3066e..73a1c2c3b 100644
--- a/lib/redmine/scm/adapters/cvs_adapter.rb
+++ b/lib/redmine/scm/adapters/cvs_adapter.rb
@@ -373,7 +373,11 @@ module Redmine
def scm_cmd(*args, &block)
full_args = [CVS_BIN, '-d', root_url]
full_args += args
- ret = shellout(full_args.map { |e| shell_quote e.to_s }.join(' '), &block)
+ full_args_locale = []
+ full_args.map do |e|
+ full_args_locale << scm_iconv(@path_encoding, 'UTF-8', e)
+ end
+ ret = shellout(full_args_locale.map { |e| shell_quote e.to_s }.join(' '), &block)
if $? && $?.exitstatus != 0
raise ScmCommandAborted, "cvs exited with non-zero status: #{$?.exitstatus}"
end