diff options
author | Andreas Schneider <mail@cynapses.org> | 2009-05-03 18:22:10 +0000 |
---|---|---|
committer | Andreas Schneider <mail@cynapses.org> | 2009-05-03 18:22:10 +0000 |
commit | c98fce85963d1dc2c2c250af8e400081805fe951 (patch) | |
tree | 1cac2ed94a464274125b061eab38165a2d1b30a3 | |
parent | e97275c7bc3afa0143fbddf22d4102d50c9bb233 (diff) | |
download | libssh-c98fce85963d1dc2c2c250af8e400081805fe951.tar.gz libssh-c98fce85963d1dc2c2c250af8e400081805fe951.tar.xz libssh-c98fce85963d1dc2c2c250af8e400081805fe951.zip |
Reformat some code of channel_default_bufferize().
git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@683 7dcaeef0-15fb-0310-b436-a5af3365683c
-rw-r--r-- | libssh/channels.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/libssh/channels.c b/libssh/channels.c index 22d19493..fd7ef0f7 100644 --- a/libssh/channels.c +++ b/libssh/channels.c @@ -581,18 +581,21 @@ void channel_handle(SSH_SESSION *session, int type){ leave_function(); } -/* when data has been received from the ssh server, it can be applied to the known - user function, with help of the callback, or inserted here */ -/* XXX is the window changed ? */ +/* + * When data has been received from the ssh server, it can be applied to the + * known user function, with help of the callback, or inserted here + * + * FIXME is the window changed? + */ int channel_default_bufferize(CHANNEL *channel, void *data, int len, int is_stderr) { struct ssh_session *session = channel->session; ssh_log(session, SSH_LOG_RARE, "placing %d bytes into channel buffer (stderr=%d)", len, is_stderr); - if (! is_stderr) { + if (is_stderr == 0) { /* stdout */ - if(channel->stdout_buffer == NULL) { + if (channel->stdout_buffer == NULL) { channel->stdout_buffer = buffer_new(); if (channel->stdout_buffer == NULL) { return -1; |