undefined method `strip' for nil:NilClass error with JRuby 1.7.2 (#12228).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11278 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2013-01-27 10:50:19 +00:00
parent fb663210b2
commit 7643281510
1 changed files with 3 additions and 3 deletions

View File

@ -104,13 +104,13 @@ module Redmine
re = %r{^V\s+(#{Regexp.escape(prefix)})?(\/?)([^\/]+)(\/?)\s+(\S+)\r?$}
io.each_line do |line|
next unless line =~ re
name_locale = $3.strip
name_locale, slash, revision = $3.strip, $4, $5.strip
name = scm_iconv('UTF-8', @path_encoding, name_locale)
entries << Entry.new({:name => name,
:path => ((path.empty? ? "" : "#{path}/") + name),
:kind => ($4.blank? ? 'file' : 'dir'),
:kind => (slash.blank? ? 'file' : 'dir'),
:size => nil,
:lastrev => Revision.new(:revision => $5.strip)
:lastrev => Revision.new(:revision => revision)
})
end
end