Page MenuHomePhabricator

When integrating with external mainloop via callbacks, need to poll() twice
Open, NormalPublic


When we use channel callbacks to handle data/eof/etc. in an async program with a main loop ... we add the file descriptor returned by sshgetfd() to the external main loop (in this case GLib). Once we get a POLLIN or POLLOUT from our external main loop, we have to use ssheventsdopoll() to ask libssh to poll() once again.

This results in a needless call to poll() and twice the context switches.

Event Timeline

migration created this object with visibility "Restricted Project (Project)".
migration created this object with edit policy "Restricted Project (Project)".
asn changed the visibility from "Restricted Project (Project)" to "Public (No Login Required)".