[Gambas-bugtracker] Bug #2310: Gambas Apps have isssues talking to other gambas apps started with exec

bugtracker at gambaswiki.org bugtracker at gambaswiki.org
Fri Jul 16 12:00:25 CEST 2021


http://gambaswiki.org/bugtracker/edit?object=BUG.2310&from=L21haW4-

Comment #6 by Benoît MINISINI:

You must first fix your applications:

- Standard input and output streams are buffered. So your "cat" program must flush its output when it must be sent to the other process. Otherwise the data stays in the buffer, and the other process don't see it.

- You should do nothing except Application_Read(). Now, when the other process closes its input stream, the read watch is automatically stopped, and the process exit, having nothing to watch anymore.

- In the sending process, same thing. Standard output streams are buffered, so you must flush them if you want to be sure that the data is actually sent.




More information about the Bugtracker mailing list