aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ssh/src/ssh_connection_handler.erl
diff options
context:
space:
mode:
authorErlang/OTP <[email protected]>2015-04-10 13:09:50 +0200
committerErlang/OTP <[email protected]>2015-04-10 13:09:50 +0200
commited8b9b2d95203b2cfec53d346c768480ade7d9ae (patch)
treea139faa1c24231c767a97fc33a653ccfc087b724 /lib/ssh/src/ssh_connection_handler.erl
parent545890576542e4be630df8772654b99bd0306f62 (diff)
parentaf095b98e089e3a4a5db5012dbdc0d579367a907 (diff)
downloadotp-ed8b9b2d95203b2cfec53d346c768480ade7d9ae.tar.gz
otp-ed8b9b2d95203b2cfec53d346c768480ade7d9ae.tar.bz2
otp-ed8b9b2d95203b2cfec53d346c768480ade7d9ae.zip
Merge branch 'ia/ssh/packet_size0/OTP-12645' into maint-17
* ia/ssh/packet_size0/OTP-12645: ssh: Reset upgrade instructions to default ssh: Change version (vsn.mk) ssh: Option minimal_remote_max_packet_size and test cases ssh: fix loop bug for zero maximum_packet_size. ssh: Add ssh_info:print/1 to write onto a file descriptor ssh: Add {active, false} to ssh listen socket ssh: Change send_buf implementation from list to queue ssh: Remove error report
Diffstat (limited to 'lib/ssh/src/ssh_connection_handler.erl')
-rw-r--r--lib/ssh/src/ssh_connection_handler.erl11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/ssh/src/ssh_connection_handler.erl b/lib/ssh/src/ssh_connection_handler.erl
index 68523aa72b..e1f2e059e8 100644
--- a/lib/ssh/src/ssh_connection_handler.erl
+++ b/lib/ssh/src/ssh_connection_handler.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2008-2014. All Rights Reserved.
+%% Copyright Ericsson AB 2008-2015. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -751,7 +751,9 @@ handle_sync_event({open, ChannelPid, Type, InitialWindowSize, MaxPacketSize, Dat
user = ChannelPid,
local_id = ChannelId,
recv_window_size = InitialWindowSize,
- recv_packet_size = MaxPacketSize},
+ recv_packet_size = MaxPacketSize,
+ send_buf = queue:new()
+ },
ssh_channel:cache_update(Cache, Channel),
State = add_request(true, ChannelId, From, State2),
start_timeout(ChannelId, From, Timeout),
@@ -1241,10 +1243,9 @@ event(Event, StateName, State) ->
handle_disconnect(DisconnectMsg, State);
throw:{ErrorToDisplay, #ssh_msg_disconnect{} = DisconnectMsg} ->
handle_disconnect(DisconnectMsg, State, ErrorToDisplay);
- _:Error ->
- log_error(Error),
+ _:_ ->
handle_disconnect(#ssh_msg_disconnect{code = error_code(StateName),
- description = "Internal error",
+ description = "Invalid state",
language = "en"}, State)
end.
error_code(key_exchange) ->