Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [ptp-user] eclipse console eats output

Christoph,

Good point. There are a lot of factors involved in getting the output to the Eclipse console, which I won't go into here. Suffice to say that combining both buffered and un-buffered I/O in this way is bound to cause issues like this. You could try using printf or fputc instead of write to confirm.

Regards,
Greg

On Dec 14, 2012, at 1:46 PM, Christoph Pospiech <Christoph.Pospiech@xxxxxxxxxx> wrote:

On Thursday, December 13, 2012 12:00:07 Greg Watson wrote:
> Christoph,
>
> I'd say it's a buffering issue. Try putting a fflush(stdout) at the end of
> the program to see if that makes any difference.
>
> Regards,
> Greg

 

Greg,

 

as a matter of fact - fflush(stdout) didn't make any difference.

 

Perhaps not so surprising, as fflush(FILE *stream) is part of stdio.h and acts on stdio streams, while the string "abcdefghij" are written by POSIX write to a POSIX file handle. AFAIK the buffering that ffflush can flush happens in the stdio layer.

 

But I agree that it looks like a buffering issue, perhaps some buffering in the machinery that picks the output from the program and sends it to the eclipse console ?
--

 

Mit freundlichen Grüßen / Kind regards

 

Dr. Christoph Pospiech
High Performance & Parallel Computing
Phone: +49-351 86269826
Mobile: +49-171-765 5871
-------------------------------------------------------------------------------------------------------------------------------------------
IBM Deutschland GmbH / Vorsitzender des Aufsichtsrats: Martin Jetter
Geschäftsführung: Martina Koederitz (Vorsitzende), Reinhard Reschke, Dieter Scholz, Gregor Pillen, Joachim Heel, Christian Noll
Sitz der Gesellschaft: Ehningen / Registergericht: Amtsgericht Stuttgart, HRB 14562 / WEEE-Reg.-Nr. DE 99369940

 

_______________________________________________
ptp-user mailing list
ptp-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/ptp-user


Back to the top