From e5b7f259be44efa45ec8ee3355577e691754cc63 Mon Sep 17 00:00:00 2001 From: Sverker Eriksson Date: Fri, 20 May 2016 18:10:25 +0200 Subject: erts: Remove unnecessary halt string truncation as erlang:halt does it for us now --- erts/preloaded/src/init.erl | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'erts/preloaded') diff --git a/erts/preloaded/src/init.erl b/erts/preloaded/src/init.erl index e8f02f5056..45468b3b9c 100644 --- a/erts/preloaded/src/init.erl +++ b/erts/preloaded/src/init.erl @@ -90,7 +90,6 @@ -define(ON_LOAD_HANDLER, init__boot__on_load_handler). --define(MAX_HALT_STRING_SIZE, 199). debug(false, _) -> ok; debug(_, T) -> erlang:display(T). @@ -180,7 +179,7 @@ stop(Status) when is_integer(Status), Status >= 0 -> stop(Status) when is_list(Status) -> case is_bytelist(Status) of true -> - stop_1(limit_halt_string(Status)); + stop_1(Status); false -> erlang:error(badarg) end; @@ -305,12 +304,7 @@ things_to_string([]) -> "". halt_string(String, List) -> - limit_halt_string(String ++ things_to_string(List)). - -limit_halt_string(String) when length(String) < ?MAX_HALT_STRING_SIZE -> - String; -limit_halt_string(String) -> - lists:sublist(String, ?MAX_HALT_STRING_SIZE-1). + String ++ things_to_string(List). %% String = string() %% List = [string() | atom() | pid() | number()] -- cgit v1.2.3