1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-07-28 01:41:48 +03:00

Fix infinite loop in exec example

This commit is contained in:
Aris Adamantiadis
2010-01-03 23:15:55 +01:00
parent 055fbe1d87
commit 1b15896e8b

View File

@ -36,7 +36,7 @@ int main(void) {
}
while ((rc = channel_read(channel, buffer, sizeof(buffer), 0)) >= 0) {
while ((rc = channel_read(channel, buffer, sizeof(buffer), 0)) > 0) {
fwrite(buffer, 1, rc, stdout);
}