-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Fix bug in Path.join. Fix #4252. #4253
New issue
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
Conversation
lib/elixir/lib/path.ex
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not very confident with this byte_size call. Maybe we could fix this by moving remove_dirsep inside the do_join calls below and only call it when appropriate? Can you give this alternative solution a try to see if things are better or worse? Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I'll give it a try!
|
Thank you! I have added a comment! |
aa19e27 to
aae18d9
Compare
|
@josevalim I tried to move the logic to Maybe it would be better to move the last |
lib/elixir/lib/path.ex
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need "" inside the pattern?
<<_, "">> is the same as <<_>>.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, I changed the code a little!
|
Maybe we can change remove_dirsep to not do anything if it receives only On Tuesday, February 2, 2016, Daniel Perez notifications@github.com wrote:
José Valimwww.plataformatec.com.br |
|
@tuvistavie I have added a new comment so maybe we explicitly check for |
aae18d9 to
85d6ca6
Compare
|
@josevalim Sorry for the delay. I changed the |
Fix bug in Path.join. Fix #4252.
This should fix #4252.