diff options
author | Niclas Eklund <[email protected]> | 2011-05-19 14:24:12 +0200 |
---|---|---|
committer | Niclas Eklund <[email protected]> | 2011-05-19 14:24:12 +0200 |
commit | 2a3bb0347d691703cc1eb9b1fd6f29f489ff4e3a (patch) | |
tree | 33d3882b3183f5c134d589828a5f5584ce6707f2 /lib | |
parent | e4cf4ecdbf0a276d264866b1c1a125587ff75250 (diff) | |
parent | 26b854ade6f1d89379f6337b18dde32e9abb9615 (diff) | |
download | otp-2a3bb0347d691703cc1eb9b1fd6f29f489ff4e3a.tar.gz otp-2a3bb0347d691703cc1eb9b1fd6f29f489ff4e3a.tar.bz2 otp-2a3bb0347d691703cc1eb9b1fd6f29f489ff4e3a.zip |
Merge branch 'maint-r14' into dev
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ssh/doc/src/notes.xml | 14 | ||||
-rw-r--r-- | lib/ssh/src/ssh.appup.src | 2 | ||||
-rw-r--r-- | lib/ssh/src/ssh_connection_handler.erl | 14 | ||||
-rw-r--r-- | lib/ssh/vsn.mk | 2 |
4 files changed, 30 insertions, 2 deletions
diff --git a/lib/ssh/doc/src/notes.xml b/lib/ssh/doc/src/notes.xml index 4f546a37ed..71f3941577 100644 --- a/lib/ssh/doc/src/notes.xml +++ b/lib/ssh/doc/src/notes.xml @@ -29,6 +29,20 @@ <file>notes.xml</file> </header> +<section><title>Ssh 2.0.7</title> + <section><title>Fixed Bugs and Malfunctions</title> + <list> + <item> + <p> + An unexpected message would crash the ssh_connection_handler and close + the connection. Now an error message is generated instead.</p> + <p> + Own Id: OTP-9273</p> + </item> + </list> + </section> +</section> + <section><title>Ssh 2.0.6</title> <section><title>Fixed Bugs and Malfunctions</title> <list> diff --git a/lib/ssh/src/ssh.appup.src b/lib/ssh/src/ssh.appup.src index 37f24e2463..974145836c 100644 --- a/lib/ssh/src/ssh.appup.src +++ b/lib/ssh/src/ssh.appup.src @@ -19,10 +19,12 @@ {"%VSN%", [ + {"2.0.6", [{load_module, ssh_userreg, soft_purge, soft_purge, []}]}, {"2.0.5", [{load_module, ssh_userreg, soft_purge, soft_purge, []}, {load_module, ssh_connection_handler, soft_purge, soft_purge, [ssh_userreg]}]} ], [ + {"2.0.6", [{load_module, ssh_userreg, soft_purge, soft_purge, []}]}, {"2.0.5", [{load_module, ssh_userreg, soft_purge, soft_purge, []}, {load_module, ssh_connection_handler, soft_purge, soft_purge, [ssh_userreg]}]} ] diff --git a/lib/ssh/src/ssh_connection_handler.erl b/lib/ssh/src/ssh_connection_handler.erl index 3193be2510..00b30e5434 100644 --- a/lib/ssh/src/ssh_connection_handler.erl +++ b/lib/ssh/src/ssh_connection_handler.erl @@ -569,7 +569,19 @@ handle_info({CloseTag, _Socket}, _StateName, #state{transport_close_tag = CloseTag, %%manager = Pid, ssh_params = #ssh{role = _Role, opts = _Opts}} = State) -> %%ok = ssh_connection_manager:delivered(Pid), - {stop, normal, State}. + {stop, normal, State}; +handle_info(UnexpectedMessage, StateName, #state{ssh_params = SshParams} = State) -> + Msg = lists:flatten(io_lib:format( + "Unexpected message '~p' received in state '~p'\n" + "Role: ~p\n" + "Peer: ~p\n" + "Local Address: ~p\n", [UnexpectedMessage, StateName, + SshParams#ssh.role, SshParams#ssh.peer, + proplists:get_value(address, SshParams#ssh.opts)])), + error_logger:info_report(Msg), + {next_state, StateName, State}. + + %%-------------------------------------------------------------------- %% Function: terminate(Reason, StateName, State) -> void() %% Description:This function is called by a gen_fsm when it is about diff --git a/lib/ssh/vsn.mk b/lib/ssh/vsn.mk index d0861b3ddc..d79038df29 100644 --- a/lib/ssh/vsn.mk +++ b/lib/ssh/vsn.mk @@ -1,5 +1,5 @@ #-*-makefile-*- ; force emacs to enter makefile-mode -SSH_VSN = 2.0.6 +SSH_VSN = 2.0.7 APP_VSN = "ssh-$(SSH_VSN)" |