We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
headius
Learn more about funding links in repositories.
Report abuse
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Having the returned string be different encoding than the input string to File.basename seems like a bug.
Full reproduction:
% rvm 2.1.4,1.7.16.1 do ruby test.rb # Ruby 2.1.4 Windows-31J Windows-31J # JRuby 1.7.16.1 Windows-31J UTF-8
Code:
# encoding: Windows-31J x = "/hello/world" puts x.encoding puts File.basename(x).encoding
The text was updated successfully, but these errors were encountered:
Originally reported in Logstash: elastic/logstash#2155
Sorry, something went wrong.
A bug indeed.
Preserve incoming encoding in File.basename. Fixes #2259.
2c1c909
Thanks so much! <3
No branches or pull requests
Having the returned string be different encoding than the input string to File.basename seems like a bug.
Full reproduction:
Code:
The text was updated successfully, but these errors were encountered: