(e-mail address removed) said:
Richard , with all respect
U haven't provided any reference for your claim that fflush( stdin ) is
undefined, so for me
they are still only your words and not "The Standard"
You mean I haven't quoted this often enough before in comp.lang.c? Okay,
here we go again:
4.9.5.2 The fflush function
Synopsis
#include <stdio.h>
int fflush(FILE *stream);
Description
If stream points to an output stream or an update stream in which
the most recent operation was output, the fflush function causes any
unwritten data for that stream to be delivered to the host environment
to be written to the file; otherwise, the behavior is undefined.
If stream is a null pointer, the fflush function performs this
flushing action on all streams for which the behavior is defined
above.
(C99 contains similar wording.)
<man page snipped>
Man pages don't define the language.