On Thu, Aug 30, 2018 at 10:57:21AM +0000, Mark Morgan Lloyd wrote: > Ah yes, that's it, thanks very much. > > WriteLn(StdErr, Format('# Socket %s, clock resolution %8.6f uSec', > [socketName, ts.tv_nsec / 1000])); > ttextrec(StdErr).flushfunc:= ttextrec(StdErr).inoutfunc; > while true do begin > ttextrec(Output).flushfunc:= ttextrec(Output).inoutfunc; > i := fprecv(client, @buff, 1024, 0);
You only need to set flushfunc once at startup (for standard handles) or just after opening a file. The whole output vs stdout thing has confused me in the past, too. Henry _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal