1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Pathname: Simplified Pathname#mountpoint?

Removed unnecessary comparison in mountpoint?
[Fix GH-1927]

From: John Whitson <john.whitson@gmail.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64273 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2018-08-10 12:04:24 +00:00
parent d370a3d44c
commit 74325360d3

View file

@ -193,8 +193,7 @@ class Pathname
begin
stat1 = self.lstat
stat2 = self.parent.lstat
stat1.dev == stat2.dev && stat1.ino == stat2.ino ||
stat1.dev != stat2.dev
stat1.dev != stat2.dev || stat1.ino == stat2.ino
rescue Errno::ENOENT
false
end