On 25 Nov 2010, at 12:24, Anton Kavalenka wrote:

What I have to do to properly initialize these defaults for new threads AFTER capturing StdOut?

Store a copy of your stdout in a global variable, and after creating a new thread

  close(stdout);
  stdout:=myglobalstdout;

(and maybe the same for "output").

One possible problem: the output handles are automatically flushed when a thread exits (so that may cause synchronisation issues).


Jonas
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to