문제

I managed to read ssh verbose mode output with QProcess. But, like in the terminal, if ssh is successfully logged in, it will stop the process. But, in the terminal, I can see the verbose output if there are connections using ssh.
I make ssh for dynamic forwarding like this command:

ssh -vfCND31338 -l username -p 22 myhost

the problem is that QProcess will stop reading output when ssh successfully logged in. for the rest verbose, it doesn't read anymore. What should I do with this?

도움이 되었습니까?

해결책

I do not think this is possible off-hand with stock Qt, but e.g. you could poll with a certain interval if the ssh session is still running. In that case, pgrep is your friend.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top