Hi Victor, I reported the bug: http://bugzilla.scilab.org/show_bug.cgi?id=11969
and proposed a patch: http://codereview.scilab.org/#/c/9394/ Thanks Calixte On 08/10/2012 14:48, Victor Noël wrote:
Hi, We need in a joint research/industrial project to run scilab functions from Java. Since javasci does not allow multiple engine to run at the same time (as we need each of these execution to be persistent during a long time with global variables, and there could be name clashes between them), we decided to spawn the scilab cli for each function and interact with it using stdin and stdout. This works well, but ONLY under windows. For a reason we ignore, stdout does not seem to produce any output under Linux. I defined a simple test case to illustrate the problem, it runs under windows but not under Linux. It is joined to this email. Running it should produce the display of "test" in the console. To illustrate the fact that the problem here is not linked to deadlocks created by threads and a small stream buffer (as it is a famous reason for this kind of problem), I put the reading of stderr and stdout in threads. What we noticed is the following: - closing stdin unblocks stdout (but makes the process useless) - redirecting stdout to a file does not work either - redirecting stdout to the java process's stdout does work! I have the feeling this is linked Scilab itself and not just to the java code responsible of executing processes, that's why I ask the question here, but I may be wrong, and in that case, I'm sorry for the noise. This is really blocking and I'm starting to get desperate about fixing this (even more because I had a lot of hopes in porting our prototype to Linux :) Thank you for any help you can provide Victor _______________________________________________ users mailing list [email protected] http://lists.scilab.org/mailman/listinfo/users
-- Calixte Denizet Software Development Engineer ----------------------------------------------------------- Scilab Enterprises 143bis rue Yves Le Coz - 78000 Versailles, France http://www.scilab-enterprises.com
_______________________________________________ users mailing list [email protected] http://lists.scilab.org/mailman/listinfo/users
