diff --git a/ext/mysql2/extconf.rb b/ext/mysql2/extconf.rb index bee77585..a1f6cb24 100644 --- a/ext/mysql2/extconf.rb +++ b/ext/mysql2/extconf.rb @@ -86,7 +86,7 @@ def add_ssl_defines(header) /usr/local/opt/mysql@* /usr/local/opt/mysql-client /usr/local/opt/mysql-client@* -].map { |dir| dir << '/bin' } +].map { |dir| "#{dir}/bin" } # For those without HOMEBREW_ROOT in PATH dirs << "#{ENV['HOMEBREW_ROOT']}/bin" if ENV['HOMEBREW_ROOT'] diff --git a/spec/mysql2/client_spec.rb b/spec/mysql2/client_spec.rb index 14f446df..a8f90da2 100644 --- a/spec/mysql2/client_spec.rb +++ b/spec/mysql2/client_spec.rb @@ -886,7 +886,7 @@ def run_gc end it "should carry over the original string's encoding" do - str = "abc'def\"ghi\0jkl%mno" + str = "abc'def\"ghi\0jkl%mno".dup escaped = Mysql2::Client.escape(str) expect(escaped.encoding).to eql(str.encoding)