mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 12:20:42 +09:00
poll: return error on poll() when pollset is empty
(cherry picked from commit 222a0d78ca)
This commit is contained in:
committed by
Andreas Schneider
parent
bbdef245a1
commit
5826cb6ab2
@@ -581,7 +581,7 @@ int ssh_poll_ctx_dopoll(ssh_poll_ctx ctx, int timeout) {
|
||||
int revents;
|
||||
|
||||
if (!ctx->polls_used)
|
||||
return 0;
|
||||
return SSH_ERROR;
|
||||
|
||||
rc = ssh_poll(ctx->pollfds, ctx->polls_used, timeout);
|
||||
if(rc < 0)
|
||||
|
||||
Reference in New Issue
Block a user