aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Svensson <[email protected]>2014-01-23 10:18:37 +0100
committerHenrik Nord <[email protected]>2014-02-03 14:47:43 +0100
commit55222b92e84960c66fcd1a220c54917f3dfbda2e (patch)
tree419dea921734326b2b4aa2a748939469d838a6e4
parent0925058a5fdf90de95122b934d995f609a075594 (diff)
downloadotp-55222b92e84960c66fcd1a220c54917f3dfbda2e.tar.gz
otp-55222b92e84960c66fcd1a220c54917f3dfbda2e.tar.bz2
otp-55222b92e84960c66fcd1a220c54917f3dfbda2e.zip
lib/mnesia/test/ - Replace reverse(tl(reverse(L))) with lists:droplast/1
-rw-r--r--lib/mnesia/test/mnesia_frag_test.erl4
-rw-r--r--lib/ssh/src/ssh_sftpd.erl2
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/mnesia/test/mnesia_frag_test.erl b/lib/mnesia/test/mnesia_frag_test.erl
index d3f6762af7..6695fbc880 100644
--- a/lib/mnesia/test/mnesia_frag_test.erl
+++ b/lib/mnesia/test/mnesia_frag_test.erl
@@ -461,7 +461,7 @@ nice_iter_access(Tab, FragNames, RawRead) ->
ExpectedLast = lists:last(Keys),
?match(ExpectedLast, mnesia:last(Tab)),
- ExpectedAllPrev = ['$end_of_table' | lists:reverse(tl(lists:reverse(Keys)))],
+ ExpectedAllPrev = ['$end_of_table' | lists:droplast(Keys)],
?match(ExpectedAllPrev, lists:map(fun(K) -> mnesia:prev(Tab, K) end, Keys)),
ExpectedAllNext = tl(Keys) ++ ['$end_of_table'],
@@ -477,7 +477,7 @@ evil_iter_access(Tab, FragNames, RawRead) ->
ExpectedLast = lists:last(Keys),
?match(ExpectedLast, mnesia:last(Tab)),
- ExpectedAllPrev = ['$end_of_table' | lists:reverse(tl(lists:reverse(Keys)))],
+ ExpectedAllPrev = ['$end_of_table' | lists:droplast(Keys)],
?match(ExpectedAllPrev, lists:map(fun(K) -> mnesia:prev(Tab, K) end, Keys)),
ExpectedAllNext = tl(Keys) ++ ['$end_of_table'],
diff --git a/lib/ssh/src/ssh_sftpd.erl b/lib/ssh/src/ssh_sftpd.erl
index 50cbdd5e45..2bc68e62bb 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:droplast(AccPathComps0))) of
+ Path = case lists:droplast(AccPathComps0) of
[] ->
"";
AccPathComps ->