From b1a93cb1d16e8a65a608727b55ef800dcc75351c Mon Sep 17 00:00:00 2001 From: Hans Svensson Date: Thu, 23 Jan 2014 09:56:04 +0100 Subject: Use lists:droplast/1 in orber/orber_interceptors.erl --- lib/orber/src/orber_interceptors.erl | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'lib/orber') diff --git a/lib/orber/src/orber_interceptors.erl b/lib/orber/src/orber_interceptors.erl index 407823ea79..62870b35b5 100644 --- a/lib/orber/src/orber_interceptors.erl +++ b/lib/orber/src/orber_interceptors.erl @@ -112,7 +112,7 @@ pop_system_message_interceptor(out) -> [{_, []}] -> ok; [{_, Interceptors}] -> - ets:insert(orber_interceptors, {message_out_interceptors, remove_last_element(Interceptors)}); + ets:insert(orber_interceptors, {message_out_interceptors, lists:droplast(Interceptors)}); _ -> corba:raise(#'INTERNAL'{completion_status=?COMPLETED_NO}) end. @@ -151,12 +151,3 @@ apply_message_interceptors([], F, ObjRef, Bytes) -> apply_message_interceptors([M | Rest], F, ObjRef, Bytes) -> apply_message_interceptors(Rest, F, ObjRef, apply(M, F, [ObjRef, Bytes])). - -remove_last_element([]) -> - []; -remove_last_element([M]) -> - []; -remove_last_element([M |Tail]) -> - remove_last_element([Tail]). - - -- cgit v1.2.3