aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Svensson <[email protected]>2014-01-23 10:16:12 +0100
committerHans Svensson <[email protected]>2014-01-24 23:07:29 +0100
commit0925058a5fdf90de95122b934d995f609a075594 (patch)
tree4b023b120156fabf323888b17d3ce68162ea37af
parent4f9b1cb7700e3460c95bbf15f315a35cfe0a76a3 (diff)
downloadotp-0925058a5fdf90de95122b934d995f609a075594.tar.gz
otp-0925058a5fdf90de95122b934d995f609a075594.tar.bz2
otp-0925058a5fdf90de95122b934d995f609a075594.zip
lib/ssh - Replace reverse(tl(reverse(L))) with lists:droplast/1
-rw-r--r--lib/ssh/src/ssh_sftpd.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ssh/src/ssh_sftpd.erl b/lib/ssh/src/ssh_sftpd.erl
index 174ca0126b..50cbdd5e45 100644
--- a/lib/ssh/src/ssh_sftpd.erl
+++ b/lib/ssh/src/ssh_sftpd.erl
@@ -675,7 +675,7 @@ resolve_symlinks_2(["." | RestPath], State0, LinkCnt, AccPath) ->
resolve_symlinks_2([".." | RestPath], State0, LinkCnt, AccPath) ->
%% Remove the last path component
AccPathComps0 = filename:split(AccPath),
- Path = case lists:reverse(tl(lists:reverse(AccPathComps0))) of
+ Path = case lists:droplast(AccPathComps0))) of
[] ->
"";
AccPathComps ->