Skip to content

Commit 3daef04

Browse files
committed
Trap exit in AMQP 1.0 client proc
Trap exit signal such that terminate/3 gets executed so that the socket is closed cleanly.
1 parent ee710ca commit 3daef04

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

deps/amqp10_client/src/amqp10_client_frame_reader.erl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ callback_mode() ->
8080
[handle_event_function].
8181

8282
init([Sup, ConnConfig]) when is_map(ConnConfig) ->
83+
process_flag(trap_exit, true),
8384
Port = maps:get(port, ConnConfig, 5672),
8485
%% combined the list of `addresses' with the value of the original `address' option if provided
8586
Addresses0 = maps:get(addresses, ConnConfig, []),

0 commit comments

Comments
 (0)