First of all, a big thanks to all of you developers out there who have contributed and wrote the libssh2, and keep up the good work !
Onto my question... I'm writing an application (app1) that remotely executes another application (app2) on a server via ssh2. App2 on the server needs to report a bunch of status messages and status data back to app1 while it's processing. I'd like to have a pretty good time resolution like 10 - 3 times per second feedback at least. I was thinking of a couple of ways to achieve it. First execute app2 via libssh2_channel_exec() by app1, then: 1) have app2 write all status data to a file on the server then have app1 read the file from a timer function via sftp periodically. ( It's cumbersome) 2) have app2 write to stdout normally and have app1 just read the channel via libssh2_channel_read(). ( problem is how do i know what to read and when, and I want to be able to display the status data asyncronously, or maybe i can use channel read from a thread or timer function?) 3) or maybe is there a way to redirect the channel read in some way where it will trigger a function if there's a new line written by app2 or something like that ? Any help is appreciated ! Thanks Alian
_______________________________________________ libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
