Mercurial > dropbear
comparison cli-channel.c @ 362:1c7bf9cec6c8 channel-fix
Rearranged some more bits, marked some areas that need work.
* send_msg_channel_data() no longer allocates a separate buffer
* getchannel() handles unknown channels so callers don't have to
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Mon, 02 Oct 2006 16:34:06 +0000 |
parents | 161557a9dde8 |
children |
comparison
equal
deleted
inserted
replaced
359:78518751cb82 | 362:1c7bf9cec6c8 |
---|---|
37 unsigned int datatype; | 37 unsigned int datatype; |
38 | 38 |
39 TRACE(("enter recv_msg_channel_extended_data")) | 39 TRACE(("enter recv_msg_channel_extended_data")) |
40 | 40 |
41 channel = getchannel(); | 41 channel = getchannel(); |
42 if (channel == NULL) { | |
43 dropbear_exit("Unknown channel"); | |
44 } | |
45 | 42 |
46 if (channel->type != &clichansess) { | 43 if (channel->type != &clichansess) { |
47 TRACE(("leave recv_msg_channel_extended_data: chantype is wrong")) | 44 TRACE(("leave recv_msg_channel_extended_data: chantype is wrong")) |
48 return; /* we just ignore it */ | 45 return; /* we just ignore it */ |
49 } | 46 } |